Bug 21930 – ICE (illegal instruction) with bad code
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2021-05-18T19:27:00Z
Last change time
2021-11-08T20:45:41Z
Keywords
pull
Assigned to
No Owner
Creator
Oleg B
Comments
Comment #0 by code.viator — 2021-05-18T19:27:00Z
dustmitted code
```
import std : enforce, getSymbolsByUDA, readText;
Token string;
alias C(X) = getSymbolsByUDA!(__traits(parent, X), X);
enum A;
struct U { static foreach (T; C!A) {} }
class R { this(string) { } }
@system main() { new R; }
```
output on dmd 2.096.1
```
app.d(2): Error: undefined identifier `Token`
app.d(7): Error: function `D main` must return `int` or `void`
fish: “dmd app.d” terminated by signal SIGILL (Illegal instruction)
```
Comment #1 by dlang-bot — 2021-10-28T04:04:39Z
@BorisCarvajal created dlang/dmd pull request #13234 "Fix Issue 21930 - ICE (illegal instruction) with bad code" fixing this issue:
- Fix Issue 21930 - ICE (illegal instruction) with bad code
https://github.com/dlang/dmd/pull/13234
Comment #2 by dlang-bot — 2021-10-28T07:32:28Z
dlang/dmd pull request #13234 "Fix Issue 21930 - ICE (illegal instruction) with bad code" was merged into stable:
- 186638a1e43e525e427e0d5d5aa1a5ee3c751310 by Boris Carvajal:
Fix Issue 21930 - ICE (illegal instruction) with bad code
https://github.com/dlang/dmd/pull/13234
Comment #3 by dlang-bot — 2021-11-08T20:45:41Z
dlang/dmd pull request #13279 "Merge `stable` into `master`" was merged into master:
- 8a6fcaaf74ab3a4889fb1d9938df0406c0973550 by Boris Carvajal:
Fix Issue 21930 - ICE (illegal instruction) with bad code
https://github.com/dlang/dmd/pull/13279