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

Jonathan M Davis jmdavisProg at gmail.com
Fri Jun 18 20:07:48 PDT 2010


bearophile wrote:

> Jonathan M Davis:
> 
>>Well, I would pount out that you mentioning it more or less reopens the
>>discussion,<
> 
> You are right, but probably Walter will not sue me for reopening an old
> thread ;-)
> 
> 
> In the things you are saying you seem to ignore the "goto" I have written
> two times in my answers :-)
> 

I had forgotten about that use of goto. I do find it a bit ugly, but it 
works and makes it possible to require some sort of flow control statement 
at the end of a case block, thereby avoiding bugs where you forget a break.

I can't say that I'm enamoured at the idea of having to use goto for 
fallthrough, but I wouldn't be opposed to it. Part of the issue, I suppose, 
is that not only do I definitely use fallthrough at least some of the time, 
but I'm totally used to being aware of the issue and being appropriately 
careful about it. So, I don't see it as all that big a problem. However, 
it's enough of a problem for some people (and even those who are fully aware 
of it and pay attention do screw up from time to time) that it could very 
well merit requiring a goto for fallthrough.

- Jonathan M Davis



More information about the Digitalmars-d mailing list