[Issue 3979] Order-of-compilation and forward reference errors

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jul 20 11:41:57 PDT 2010


http://d.puremagic.com/issues/show_bug.cgi?id=3979


Lars T. Kyllingstad <bugzilla at kyllingen.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |schveiguy at yahoo.com


--- Comment #3 from Lars T. Kyllingstad <bugzilla at kyllingen.net> 2010-07-20 11:41:52 PDT ---
Anxious to get this extremely annoying problem fixed, I've finally been able to
reduce it to a small test case:

  // This is a.d
  module a;
  import b;
  struct Foo {}
  Foo foo;

  // This is b.d
  module b;
  import a;
  void fun(Foo f = a.foo);

Compilation gives:

  $ dmd -c a.d b.d
  b.d(4): Error: cannot implicitly convert expression (foo) of type Foo to Foo

Phew!  It took a while, hopefully it's worth it.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list