www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - proposal: remove case keyword

reply mandel <mandel mailinator.com> writes:
Hi,

simple question; do we need to write "case"
inside a switch statement? Is it needed for parsing?
To me it seems to be superfluous
and could be removed or at least made optional.

Opinions?
Jul 28 2007
parent Jason House <jason.james.house gmail.com> writes:
mandel wrote:
 Hi,
 
 simple question; do we need to write "case"
 inside a switch statement? Is it needed for parsing?
 To me it seems to be superfluous
 and could be removed or at least made optional.
 
 Opinions?
 
What is your proposed alternate syntax for case statements. You can't replace case A: with A: because then it'd look like a line label.
Jul 28 2007