Copy Constructor DIP

Timon Gehr timon.gehr at gmx.ch
Thu Jul 12 15:27:17 UTC 2018


On 12.07.2018 17:22, Timon Gehr wrote:
> 
> alias field0 = s.tupleof[0];
> t.tupleof[0] = field0;
> alias field1 = s.tupleof[1];
> t.tupleof[1] = field1;
> alias field2 = s.tupleof[2];
> t.tupleof[2] = field2;
> 
> Error: alias `a` cannot alias an expression `tuple(s.a, s.b, s.c)[0]`
> Error: alias `b` cannot alias an expression `tuple(s.a, s.b, s.c)[1]`
> Error: alias `c` cannot alias an expression `tuple(s.a, s.b, s.c)[2]`

The error messages are actually:

Error: alias `field0` cannot alias an expression `tuple(s.a, s.b, s.c)[0]`
Error: alias `field1` cannot alias an expression `tuple(s.a, s.b, s.c)[1]`
Error: alias `field2` cannot alias an expression `tuple(s.a, s.b, s.c)[2]`



More information about the Digitalmars-d mailing list