while(...){ ... }else ...

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Sun Jan 18 15:03:40 PST 2015


"Jens Bauer" <doctor at who.no> wrote:
> On Sunday, 18 January 2015 at 18:16:47 UTC, Marc Schütz wrote:
>> Unfortunately, this would break existing code:
> 
> That is absolutely correct. Good catch. I did not think of that particular case.
> 
> However... What if the 'else', which "belongs" to while, is named
> differently, for instance ...
> 
> while(expression1)
> {
> }
> otherwise if(expression2)
> {
> }
> 
> I know otherwise is a longer word, but it would not clash with existing code.

The short answer is we are not considering such a feature. Thanks.


More information about the Digitalmars-d mailing list