> Closed would not be an access level, just an attribute orthogonal to the 
> others.
As Xiaodi pointed out, there's still no agreement on that — so basically I'm 
saying that I prefer your interpretation, because imho five access levels are 
already a alarmingly high number.

> What do you mean by the six different flavors?
1) cases with associated objects
2) raw-based enums
3) everything else (not that much different from int-based)

With the new attribute, there would be a new variant for each type, therefor 
six flavours (I choose this term because it's only small variation — but still, 
it might look quite complex to someone coming from C or Java).

The major issue I have with this change is how it will work in real live:
When I write a library and declare that I'll never add new cases to an enum, 
who will enforce this?
Will the compiler interact with git and look for release tags, or will there be 
a lockdown-command that records all cases and compares them with the last time 
the command was triggered?
This feels really brittle to me, and I haven't seen a approach that would be 
fundamental different (and better).
_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to