This is relatively minor, as there is a workaround, but it wasted about an hour to find out what was wrong, so I thought I would log it.
The two different variants of the code below work fine in XCode, with and without the named str: String parameter in the callback.
In Fire/Silver build .1925, only the second (doSomething2), without the named param, compiles.
class Test { public func doSomething( callback: ( str: String ) -> () ) { // now callback callback(str: "Hello") } public func doSomething2( callback: ( String ) -> () ) { // now callback callback("Hello") } } let t = Test() t.doSomething() { str in print( str ) } t.doSomething2() { str in print( str ) }
The error in Fire:
silvertest10.zip (149.5 KB)