Bug 13975 – ICE: dmd crash if -gc and enum member is immutable int

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2015-01-13T11:27:03Z
Last change time
2020-03-21T03:56:40Z
Keywords
pull
Assigned to
No Owner
Creator
Basile-z

Comments

Comment #0 by b2.temp — 2015-01-13T11:27:03Z
dmd crashes when compiling the following program: --- static immutable int a = 8; enum Bar {aa = a} void foo(Bar bar){} void main(){} --- only with the switches: -debug -gc the crash doesn't happend when a is declared as - static const int a = 8; - static immutable short a = 8; - static immutable uint a = 8; more generally it happens only if a is (optionnaly static) immutable int dmd version: 2.066.1 os: windows 7 32 bit
Comment #1 by code — 2015-02-20T18:31:36Z
This also crashes with when compiling only with "-g" this seems to be a general issue debug symbol generation on windows.
Comment #2 by r.sagitario — 2016-03-31T06:42:32Z
Comment #3 by github-bugzilla — 2016-04-03T07:05:13Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/5601d515db803b086ac497c8f63ba104c81e082b fix issue 13975: add missing masking of Tty https://github.com/D-Programming-Language/dmd/commit/af845b79526f6b2ad95fcdfbdd80d2b349e145f6 Merge pull request #5611 from rainers/fix_13975 fix issue 13975 - ICE: dmd crash if -gc and enum member is immutable int
Comment #4 by github-bugzilla — 2016-10-01T11:45:50Z
Commits pushed to stable at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/5601d515db803b086ac497c8f63ba104c81e082b fix issue 13975: add missing masking of Tty https://github.com/dlang/dmd/commit/af845b79526f6b2ad95fcdfbdd80d2b349e145f6 Merge pull request #5611 from rainers/fix_13975