According to Apple doc the first parameter of a function has its name identifier omitted by default thus the function
func do(something: String, else: String) {}
will be called using
do("first", else: "second")
However, in case where you declare a closure, it appears that the first parameter has to be named which is in contradiction with the documentation. Example:
func activatePlate(plate: String, activate: Bool, callback: (success: Bool) -> Void)
{
Alamofire.request(.POST, "http://httpbin.org/post").responseData {
response in
callback(success: response.result.isSuccess) // <- why that
// and not that -> callback(response.result.isSuccess)
}
}