dmd icon indicating copy to clipboard operation
dmd copied to clipboard

Incorrect location for undefined identifier in alias template instantiation

Open Ay1nDas opened this issue 7 months ago • 1 comments

enum plusOne(int x) = x + 1;
struct xyz{}

alias PlusOne =
  plusOne
  !
  xyx;

Outputs:

test.d(4): Error: undefined identifier `xyx`, did you mean struct `xyz`?
    plusOne
    ^

The error should be on line 6, pointing xyx.

Ay1nDas avatar May 16 '25 10:05 Ay1nDas

  • This issue relates to issue #21165

Ay1nDas avatar May 16 '25 13:05 Ay1nDas