> Can someone fill me in as to how this differs from (0…4).contains(x)? > > Personally I don’t like the choice for the operator, and think it’s not very > clear, if we can do the same thing with a method then I’d prefer removing the > operator to be honest.
~= is the way you customize how a type behaves when it's a pattern in a switch statement. So ~= (_: Range<T>, _: T) is responsible for making `case 1..<10` work properly. Removing it would be...unwise. -- Brent Royal-Gordon Architechies _______________________________________________ swift-evolution mailing list [email protected] https://lists.swift.org/mailman/listinfo/swift-evolution
