Re: Let's discuss enums!

From: Date: Fri, 18 Sep 2015 17:18:35 +0000
Subject: Re: Let's discuss enums!
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-88342@lists.php.net to get a copy of this message
Levi Morrison wrote on 18/09/2015 18:04:
Anything else is trying to add value in some way – in your case you are adding a primitive value that the language will automatically map for you. I'm not saying that is a bad thing but I hope you can at least recognize that it is an addition and not the bare minimum. The RFC I am planning on proposing will have only the bare minimum because it's the least controversial part and is the most useful. The other stuff we can debate about later.
That's why I was kind of surprised to see ordinal() in there in the draft - it's an additional field on each member, which in many cases has no relationship to the value being represented. Also, apologies for accidentally starting the discussion of your draft "too early", I wasn't aware that you were working on it. I was trying to offer something productive to the language, since I've been spending a lot of time talking down new features lately. :) Regards, -- Rowan Collins [IMSoP]

« previous php.internals (#88342) next »