https://issues.dlang.org/show_bug.cgi?id=13280
Issue ID: 13280
Summary: `this.sizeof` rejected as static array length in some
cases
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Keywords: rejects-valid
Severity: normal
Priority: P1
Component: DMD
Assignee: [email protected]
Reporter: [email protected]
This code should comple fine:
---
struct S
{
alias U = ubyte;
alias T1 = ubyte[this.sizeof]; // ok
alias T2 = const U[this.sizeof]; // ok
alias T3 = const ubyte[this.sizeof]; // error
}
---
main.d(6): Error: Integer constant expression expected instead of this.sizeof
---
--