3 ms·
In Objective-C, those aren't named parameters, like you might find in Python, or faked in Ruby or Groovy. They are called 'Keyword Messages'. In your example ab
by emp 15y ago
In Objective-C, those aren't named parameters, like you might find in Python, or faked in Ruby or Groovy.
They are called 'Keyword Messages'. In your example above, the method signature is replace:with:options:range:, compared to say a C++ style replaceWithOptionsRange.
It's simply a way to interleave arguments in the message send itself, inherited from Smalltalk.