ObjC2

Posted:
in macOS edited January 2014
From the WebKit change logs:

Quote:

Switch to the new ObjC 2 API, ifdefed the old code around OBJC_API_VERSION so it still works on Tiger.



Let the speculation officially commence.

Comments

  • Reply 1 of 9
    kickahakickaha Posts: 8,760member
    My guess?



    Obj-C picks up the garbage control that's been floating in the gcc CVS repository for a while now, under Apple's branch.
  • Reply 2 of 9
    kim kap solkim kap sol Posts: 2,987member
    Quote:

    Originally posted by Kickaha

    My guess?



    Obj-C picks up the garbage control that's been floating in the gcc CVS repository for a while now, under Apple's branch.




    That would make a lot of sense. I hope there is more than that in store for 10.5-only apps though.
  • Reply 3 of 9
    MarvinMarvin Posts: 14,436moderator
    I hope they change the syntax to C-style but I just know it's never gonna happen .
  • Reply 4 of 9
    chuckerchucker Posts: 5,089member
    Quote:

    Originally posted by Marvin

    I hope they change the syntax to C-style but I just know it's never gonna happen .



    Not sure what you mean by "C-style". If you don't like Objective-C's syntax, there's many bridges.
  • Reply 5 of 9
    kickahakickaha Posts: 8,760member
    I can only assume he means C++ style... and dear god NO.



    The clean separation of object-code vs. procedural-code is one thing that C++ really dropped the ball on. And named parameters are simply a godsend when dealing with new code. I mean really, quick, tell me what the following needs handed to it, and why:



    int convolve(int**, int**, float);



    Now try this one:



    (int) convolveWithSrcMatrix: (int**) targetMatrix: (int**) scale: (float);



    Self-documenting code is a huge boon.



    Not only that, but if Obj-C were to adopt C++ syntax conventions, then Obj-C++ would be *impossible* to parse. Not hard, but actually honest-to-god impossible.



    The only reason Obj-C++ can exist is because Obj-C and C++ took two different paths on syntax, and Obj-C++ is simply required right now - it's what keeps MacOS X Cocoa-native apps able to use the plethora of C++ libraries out there.
  • Reply 6 of 9
    trobertstroberts Posts: 702member
    I hope Xcode/IB/Objective-C/Cocoa gets some airtime during the keynote.
  • Reply 7 of 9
    chuckerchucker Posts: 5,089member
    Quote:

    Originally posted by troberts

    I hope Xcode/IB/Objective-C/Cocoa gets some airtime during the keynote.



    That seems a given.
  • Reply 8 of 9
    Quote:

    Originally posted by Kickaha

    I can only assume he means C++ style... and dear god NO.



    No! Please, nooooooooooooo!



    Adjusting to Objective-C's syntax was a bit of a shift for me, but as I began to do real work with the language, I quickly realized that any initial adjustment was absolutely *dwarfed* by the real-world benefits of the syntax. I also can tell you that reading Objective-C code is an absolute *joy* compared to most other languages.



    Of course, this is due largely to NeXT/Apple's naming conventions and near-religious following of them, but it is the underlying syntax that ultimately makes this near self-documeting code possible.
  • Reply 9 of 9
    I'm sure it is GC just like Kickaha mentioned. I also hope that since they killed off future developments for Java Cocoa that they will put more work in to sprucing up Obj-C. GC is a nice first step.
Sign In or Register to comment.