Is there ANY chance we can fix the bitwise operator precedence rules?

Leandro Lucarella luca at llucax.com.ar
Mon Jun 21 16:22:24 PDT 2010


Andrei Alexandrescu, el 21 de junio a las 15:31 me escribiste:
> On 06/21/2010 03:08 PM, Don wrote:
> >Andrei Alexandrescu wrote:
> >>On 06/19/2010 06:58 AM, Don wrote:
> >>>Andrei Alexandrescu wrote:
> >>>>Don wrote:
> >>>>[snip]
> >>>>>Or is too late to break backwards compatibility with B ?
> >>>>
> >>>>We can and should do it. It won't impact TDPL adversely.
> >>>
> >>>Excellent! I'll make a patch for it when I have time.
> >>
> >>Walter just gave the green light, so Don - it's up to you.
> >
> >I patched my DMD. Quite successful. It caught 8 bugs in Phobos, in code
> >written by at least 4 different people. I think everyone gets stung by
> >that B.
> 
> This is pretty amazing. Can't wait to see the checkin!
> 
> It might be interesting to see how many bugs are caught by
> restricting the switch statement.

There is already a patch for that:
http://d.puremagic.com/issues/show_bug.cgi?id=3536

Maybe is not perfect (it adds a new flavour of case to allow implicit
fall-through), but it's something =). And just to experiment with, it
should be good enough, since it makes the default case syntax forbids
implicit fall-through, so it's not necessary to change any code to try
it (if it still applies to trunk, which probably is not the case
anymore).

-- 
Leandro Lucarella (AKA luca)                     http://llucax.com.ar/
----------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------
Ya ni el cielo me quiere, ya ni la muerte me visita
Ya ni el sol me calienta, ya ni el viento me acaricia


More information about the Digitalmars-d mailing list