← Back to index
|
Original Bugzilla link
Bug 5433 – Cannot use auto functions at compile-time
Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
Other
OS
Windows
Creation time
2011-01-08T09:46:00Z
Last change time
2011-05-20T18:42:48Z
Keywords
rejects-valid
Assigned to
nobody
Creator
andrej.mitrovich
Depends on
2810
Comments
Comment #0
by andrej.mitrovich — 2011-01-08T09:46:01Z
enum var1 = foo(); // Fine enum var2 = bar(); // Error: forward reference to bar int foo() { return 1; } auto bar() { return 1; } void main() { }
Comment #1
by smjg — 2011-01-08T10:21:47Z
The same error occurs if the declaration of var2 is moved to the end (and therefore not actually a forward reference).
Comment #2
by smjg — 2011-01-12T02:46:41Z
Issue 2810 seems to be the root cause of this.
Comment #3
by andrej.mitrovich — 2011-05-20T18:42:48Z
Confirmed, issues is fixed. *** This issue has been marked as a duplicate of issue 2810 ***