Bug 1538 – "template instance forward reference to template declaration"

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Linux
Creation time
2007-09-28T16:47:00Z
Last change time
2014-02-17T22:50:24Z
Keywords
rejects-valid
Assigned to
bugzilla
Creator
webmaster

Comments

Comment #0 by webmaster — 2007-09-28T16:47:58Z
Take these two files: a.d: import b; struct A(T) {} b.d: import a; struct B {}; A!(B) foo; Now b will compile, but a gets an error (in b): [russ@russ template_forward_reference]$ dmd -c b.d [russ@russ template_forward_reference]$ dmd -c a.d b.d(3): template instance forward reference to template declaration A(T) b.d(3): Error: A!(B ) is used as a type b.d(3): variable b.foo voids have no value [russ@russ template_forward_reference]$
Comment #1 by smjg — 2007-10-29T08:06:50Z
*** This bug has been marked as a duplicate of 1392 ***