I want to return a function and invoke it as bb in the code
func bb(a: Int, b: String = "b") {
print(a, b)
}
typealias FnOfBb = (Int, String) -> Void
func cc() -> FnOfBb {
return bb
}
bb(a: 1) // is ok
cc()(a: 1) // desired, but show Error: Extraneous argument label 'a:' in call and Missing argument for parameter #2 in call
cc()(1, "str") // is ok, but different of bb