-1

This proposal doesn’t even use Swift naming style to make its point, as soon as 
you do, the reason why Swift considers argument labels to be part of the type 
signature becomes apparent. 

The author of the proposal uses the following example:

  func doSomething(x: Int, y: Int) -> Bool


This is just not Swift-y, a much better example would be:

  func sinkBattleship(atX x: Int, y: Int) -> Bool

the proposal states that the argument labels be then stripped from the type, 
which would make this method type-compatible with:

  func meetsBattingAverage(ofHits hits: Int, forRuns runs: Int) -> Bool


I don’t think it’s desirable for this to work at all… Argument labels are not 
parameter names, they are a first class part of Swift’s type system, and always 
meaningful when employed properly.


Scott
_______________________________________________
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to