Bug 20044 – Compiler crash when using an opaque struct as template parameter
Status
RESOLVED
Resolution
FIXED
Severity
critical
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2019-07-13T00:32:37Z
Last change time
2020-03-21T03:56:38Z
Keywords
ice, pull
Assigned to
No Owner
Creator
Tristan Hume
Comments
Comment #0 by trishume — 2019-07-13T00:32:37Z
https://run.dlang.io/is/Nio6z1
Reduced crashing case:
import std.variant;
struct While(T) { T[] body; }
alias Stmt = Algebraic!(While!(This));
Doesn't occur with inline This[] or when referenced as T* or T*[] instead of T[].
Comment #1 by dlang-bot — 2019-07-14T17:23:24Z
@Basile-z created dlang/dmd pull request #10173 "fix issue 20044 - Compiler crash when using an opaque struct as templ…" fixing this issue:
- fix issue 20044 - Compiler crash when using an opaque struct as template parameter
https://github.com/dlang/dmd/pull/10173
Comment #2 by dlang-bot — 2019-07-15T02:05:37Z
dlang/dmd pull request #10173 "fix issue 20044 - Compiler crash when using an opaque struct as template parameter" was merged into stable:
- 8ad3f43068bbe7bfe9a05c8e6838f102ff027f55 by Basile Burg:
fix issue 20044 - Compiler crash when using an opaque struct as template parameter
https://github.com/dlang/dmd/pull/10173