[swift-evolution] The Non-Exhaustive Enums proposal kills one of Swift's top features - change proposal
brent at architechies.com
Fri Dec 22 18:28:23 CST 2017
> On Dec 21, 2017, at 10:33 AM, Jordan Rose via swift-evolution <swift-evolution at swift.org> wrote:
> The main blocker was that such a case becomes untestable (see also "Testing invalid cases").
You can always make it testable through appropriate factoring—for example, have the `future` case call a helper function, and then explicitly invoke that helper function to test its behavior. That won't give you coverage of the `future` case itself, but there's nothing on the table that will (not even `default` when all the existing cases are covered).
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-evolution