I would like to use default values ββfor lambda arguments, for example:
func lambdaArgumentTest() -> String {
let lambda = { (optString: String = "") -> String in optString }
return lambda()
}
But the compiler seems to state that this is not possible:
Default argument is only permitted for a non-curried function parameter
Is there any good job for this? Will this be possible in future versions?
source
share