|
From: | Daniel Boyd |
Subject: | Re: OC method call in style of CPP rather than message sending |
Date: | Sun, 5 Nov 2023 09:43:27 -0600 |
I’m far from the being an authority on ObjC relative to others on this listserv, but I’ll take a stab at responding. The reason ObjC has its syntax is largely because it was developed around the same time as C++ (slightly after, but close enough) — in other words, it was developed at a time before the C++-style syntax had become a de facto standard. ObjC’s syntax style was largely derived from Smalltalk. Personally, I like ObjC’s syntax. It was certainly a change from what I was used to, but I actually prefer it in a lot of scenarios. The time when I don’t like it is when you have a line that starts with [[[[ and you have to really work to figure how many opening square brackets you need. And regarding whether you can use C++-style syntax, to use ObjC—that’s kind of a meaningless question. That syntax, for all intents and purposes *is* Objective C. I think what you’re trying to ask is whether you can do Cocoa programming using C++. Someone probably has worked on that at some point, but I suspect it’s not well supported. My suggestion is to try and learn Objective C and you may be surprised to learn that you like it after you get used to it :) Cheers, Daniel Sent from my iPhone On Nov 5, 2023, at 09:13, loserism <loserism@88.com> wrote:
|
[Prev in Thread] | Current Thread | [Next in Thread] |