Here's an example of what I'm talking about: https://developer.apple.com/documentation/foundation/nsmutableorderedset/1410287-insert
The insert function is shown as insert(_:at:)
When it's actually used, the insert function looks more like:
namesArray.insert("John", at: 3)
There's no :
after "John"
(though I suppose it could be "John":String
-- is that what it's there for?), and the ,
that actually needs to go there is not mentioned in the function signature in the documentation. Am I just supposed to know/assume that the comma goes there when I actually use it? Is this the case for all Swift functions?
Please note that this is not a question about the underscore, _
-- I understand why it's there and what it's for. I'm specifically asking about the reasons for including :
and not including ,
in the function signature.