> > Therefore the impermissible: > (()) -> () Is identical to: > (Void) -> () So to follow these rules, it must instead be: > Void -> () … and we’re back to T1 -> T2 :* )*
Wrong! If we enforce parentheses in function types, we won't be able to write Void -> () Parentheses will be required on the grammar level. The correct way to write this will be: () -> () or () -> Void The following will be legal: (Void) -> () and (()) -> () It is a function that takes a single parameter () and returns (). I additionally propose that the following should be illegal, because additional parentheses aren't needed there: ((())) -> () and () -> (()) and just (Int) and (()) Hope it cleared up things a little bit. - Anton
_______________________________________________ swift-evolution mailing list swift-evolution@swift.org https://lists.swift.org/mailman/listinfo/swift-evolution