Interesting rant about Scala's issues

Leandro Lucarella luca at llucax.com.ar
Sun Apr 6 03:31:27 PDT 2014


Walter Bright, el  5 de April a las 21:15 me escribiste:
> On 4/5/2014 6:28 PM, Leandro Lucarella wrote:
> >Walter Bright, el  5 de April a las 11:04 me escribiste:
> >>Of course, you can hide all this in a template.
> >
> >Well, you can "emulate" enums as they are now with structs too, so that
> >doesn't change anything in the argument about why to provide syntax
> >sugar for one and not the other.
> 
> 
> The argument for syntactic sugar is it must show a very large
> benefit over using a template.
> 
> Having special syntax for everything makes the language unusable.

What I mean is the current semantics of enum are as they are for
historical reasons, not because they make (more) sense (than other
possibilities). You showed a lot of examples that makes sense only
because you are used to the current semantics, not because they are the
only option or the option that makes the most sense.

Is it better to redesign enum semantics now? Probably not, but I'm just
saying :)

-- 
Leandro Lucarella (AKA luca)                     http://llucax.com.ar/
----------------------------------------------------------------------
El techo de mi cuarto lleno de cometas


More information about the Digitalmars-d-announce mailing list