What happened to the alias this = identifier syntax in 2.062?

Timon Gehr timon.gehr at gmx.ch
Fri Feb 22 13:05:01 PST 2013


On 02/22/2013 03:51 PM, Martin wrote:
> struct Test
> {
>      int i;
>      alias this = i;
> }
>
> Worked fine in 2.061 but in 2.062 I get the errors
> "Error: no identifier for declarator this" and "Error: alias cannot have
> initializer".
>
> Was something changed intentionally or is this a bug?

It is (embarrassingly!) intentional.

I consider the change bad and the reasoning behind it extraordinarily 
bad. alias this is by far whacky enough.


More information about the Digitalmars-d mailing list