Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    it is most likely what is most consistent
    especially when mixing ObjFW / Cocoa
    Letterus
    @letterus:synod.im
    [m]
    yeah. I'd go for OFCamelCase for global ones and camelCase for local functions
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    maybe LocalFunction but localVariable
    1 reply
    to differentiate
    does GNUstep use kSomeEnumValue? or GSEnumValue?
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    btw, OFUnichar or OFUniChar? 🙂
    Cocoa just uses unichar. Without a prefix. Ugh.
    so far it's of_unichar_t
    Letterus
    @letterus:synod.im
    [m]
    lol
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    I'm serious, that's an API part that cannot be changed easily later
    Letterus
    @letterus:synod.im
    [m]
    is it part of the OF public api or an internal type (I'd consider runtime functions internal as well, from an app dev's perspective, I know it's not that correct)
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    public
    it's what characterAtIndex returns
    Letterus
    @letterus:synod.im
    [m]
    but you may happen to use it in a "C-only" world as well? it fits for C type naming conventions of course…
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    yes, you could use it from C only, as every public function 😉
    Letterus
    @letterus:synod.im
    [m]
    hrhr, yes. so, let me think about a good rule for that. in Java all atomic data types would be lowercase. a char is atomic, isn't it?
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    so, of_unichar_t? 😛
    anyway, this ain't java
    it predates Java 😉
    Letterus
    @letterus:synod.im
    [m]
    yeah, it's just what I know and it seems to be comparable…
    think the raise of Java and the early cooperation of NeXT and Sun were no coincidence 😉
    since I learned Java at school the first (and only) Cocoa app I've ever written from scatch was Java based 😀
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    well, Sun was involved with OpenStep
    the NS prefix is actually "NeXT/Sun"
    NeXTstep had the NX prefix
    Letterus
    @letterus:synod.im
    [m]
    yep
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    I mean, Cocoa also has NSInteger
    so their unichar is rather out of the line
    leaning towards OFUnichar, as it was not of_uni_char_t 😉
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    After 10k lines of diff I created, I am no longer sure renaming them all is a good idea…
    Letterus
    @letterus:synod.im
    [m]
    oops
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    maybe also because I was doing too many things at once :/
    or maybe_i_just_like_this_better
    Letterus
    @letterus:synod.im
    [m]
    😀
    js#6763
    @_discord_774066653708681226:t2bot.io
    [m]
    also, OF_STRING_ENCODING_ISO_8859_15 is readable. OFISO885915StringEncoding is not.
    Letterus
    @letterus:synod.im
    [m]
    hm. I think I'd be fine if a basic char datatype has its own naming (seems to be the same about Cocoa). About all consts, enums and so on I may want to reach using IDE autocompletion I consider it very important to follow the same naming convention. convention over readability even I think.
    Letterus
    @letterus:synod.im
    [m]
    js, hit me if I'm asking stupid questions: but if we create a objfw wrapper for Gtk and compile this by using clang - do we get ARC for GTK?
    js
    @js:nil.im
    [m]

    This message is replying to a Matrix event but we were unable to find associated bridged Gitter message to put it in the appropriate threaded conversation.

    Fixed

    js
    @js:nil.im
    [m]
    still arguing with myself what type of consistency is better:
    consistency with itself or consistency with Cocoa
    e.g. it's NSUTF8StringEncoding
    of enum NSStringEncoding
    per normal conventions it should be NSStringEncodingUTF8
    so, should I do OFUTF8StringEncoding or OFStringEncodingUTF8?
    2 replies
    OpenStep is a lot less consistent than CF even!
    e.g. it's NSMakeRect, instead of NSRectNew or something.
    It's NSRectEqualToRect
    but NSEqualPoints