really stupid error

user456 user456 at 789.de
Sat Apr 1 18:41:26 UTC 2023


On Saturday, 1 April 2023 at 18:18:21 UTC, Steven Schveighoffer 
wrote:
> On 4/1/23 5:37 AM, d007 wrote:
>> ```d
>> printf("test(v[0]=%p, v[1]=%p, v[2]=%p)\n", &(arr[0][0]), 
>> &(arr[0][1]), &(arr[0][2]));
>> ubyte RR = 0;
>> printf("test(v[0]=%p, v[1]=%p, v[2]=%p)\n", &(arr[RR][0]), 
>> &(arr[RR][1]), &(arr[RR][2]));
>> ```
>> 
>> first line you get the write output, 3 diff value.
>> 
>> the seconds line you get 3 same value. change `ubyte RR = 0` 
>> into `emum RR = 0` fix the problem.
>> 
>> 
>> test with ldc2 1.32.0
>
> Do you have a complete test case? If so, please file a bug 
> report.
>
> https://issues.dlang.org
>
> -Steve

I have created this https://godbolt.org/z/ePxshnvvc but I dont 
know if DMD is affected. That seems to be a bug specific to LDC.


More information about the Digitalmars-d mailing list