Attributes on Enum Members: Call for use cases.

Jonathan M Davis newsgroup.d at jmdavisprog.com
Tue Nov 28 17:59:39 UTC 2017


On Tuesday, November 28, 2017 18:24:27 Jacob Carlborg via Digitalmars-d 
wrote:
> On 2017-11-28 03:20, Michael V. Franklin wrote:
> > For those who might want to know, Walter has informed me that this
> > change will require a DIP.
>
> That's unfortunate. It should be the opposite, a DIP on why enum members
> should not support attributes. It goes against consistency (turtles all
> the way down).

For better or worse, Walter and Andrei seem to have gotten into a mode where
just about any language change which isn't an outright bug fix requires a
DIP. And a lack of turtles all the way down someplace is not really a bug
fix (especially since it's sometimes debatable as to whether it's desirable
in a particular case or whether something actually qualifies as being an
issue with turtles all the way down; it's not always clearcut). However, a
lack of consistency _is_ often a good argument - particularly if it's a lack
of turtles all the way down consistency; arguments along those lines are how
we ended up with stuff like local imports. So, if it's really that clear
that enums really should be allowed to have attributes, then the DIP will
probably be accepted.

- Jonathan M Davis



More information about the Digitalmars-d mailing list