Bug 20231 – unable to resolve forward reference with stdint on Windows x86

Status
NEW
Severity
major
Priority
P2
Component
druntime
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2019-09-19T21:33:33Z
Last change time
2024-12-07T13:39:39Z
Assigned to
No Owner
Creator
Thibaut CHARLES
Moved to GitHub: dmd#17390 →

Comments

Comment #0 by cromfr — 2019-09-19T21:33:33Z
The following code does not compile on Windows x86: ``` import std.stdint; enum Yolo: uint32_t { a = 42, } void main(){} ``` test.d(2): Error: enum `test.Yolo` unable to resolve forward reference in definition Compiling this code on Linux x86 / x86_64 works perfectly. Yolo types uint32_t and int32_t cause the error, other types seems to work fine. Affected versions are from dmd 2.081 to 2.088.0. 2.080.1 is not affected. I'd bet the issue is related to how uint32_t and int32_t are defined in https://github.com/dlang/druntime/blob/master/src/core/stdc/stdint.d#L46
Comment #1 by robert.schadek — 2024-12-07T13:39:39Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/17390 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB