[Python-Dev] PEP 435: initial values must be specified? Yes (original) (raw)
Ethan Furman ethan at stoneleaf.us
Mon May 6 02:44:42 CEST 2013
- Previous message: [Python-Dev] PEP 435: initial values must be specified? Yes
- Next message: [Python-Dev] PEP 435: initial values must be specified? Yes
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 05/05/2013 04:57 PM, Greg Ewing wrote:
Ethan Furman wrote:
--> class Color(Enum): ... red, green, blue ...
--> class MoreColor(Color): ... red, orange, yellow ... --> type(MoreColor.red) is MoreColor False This argument no longer applies, since we're not allowing enums to be extended.
Actually, it does:
--> class Color(Enum): ... black, red, green, blue, cyan, magenta, yellow, black # oops!
--
Ethan
- Previous message: [Python-Dev] PEP 435: initial values must be specified? Yes
- Next message: [Python-Dev] PEP 435: initial values must be specified? Yes
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]