Bug 23412 – void init member detection does not account for static arrays

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2022-10-14T11:40:43Z
Last change time
2022-10-15T13:18:41Z
Keywords
pull, safe
Assigned to
No Owner
Creator
Dennis

Comments

Comment #0 by dkorpel — 2022-10-14T11:40:43Z
```D struct S { int* x = void; } void main() @safe { S s0; // error S[1] s1; // no error, but should error as well } ```
Comment #1 by dlang-bot — 2022-10-14T11:42:10Z
@dkorpel created dlang/dmd pull request #14559 "Fix 23412 - void init member detection does not account for static arrays" fixing this issue: - Fix 23412 - void init member detection does not account for static arrays https://github.com/dlang/dmd/pull/14559
Comment #2 by dlang-bot — 2022-10-15T13:18:41Z
dlang/dmd pull request #14559 "Fix 23412 - void init member detection does not account for static arrays" was merged into master: - c64a1459fe2ee5f35605a3b6d8863a5e89adc50d by Dennis Korpel: Fix 23412 - void init member detection does not account for static arrays https://github.com/dlang/dmd/pull/14559