Re:Cargo-cult typing, or: Objective-C's default type is id
by vor_ on Wednesday March 05, 2014 @07:33PM
(#7351022)
There's nothing difficult about it. It's just a pedantic and pointless distinction most of the time. To be more specific about what I was referring to, some folks on the Objective-C mailing list didn't even want methods in a protocol to be called methods. Instead they are to be called "method signatures". I roll my eyes.
Re:Cargo-cult typing, or: Objective-C's default type is id
by mpweiher on Thursday March 06, 2014 @02:26AM
(#7352373)
Well, maybe that's because they aren't actually methods?
A method is an implementation, something that executes. Protocols do not contain implementations, though there have been proposals to actually add methods to protocols. Talking about such a proposal to add methods to protocols becomes difficult when you have called the messages that are already there methods...
Yes they are similar, and most often sending a message of a particular name will invoke a method of that name via the messenger. But they are different in ways that matter, so it is better to use the correct terminology.
However, it's not really a big deal, you will typically be understood either way. However, I don't quite understand why using the correct terminology is so difficult. "Send a message" vs. "Call a method". Same number of words, same number of syllables. OK, 1 letter more to type...