[Issue 3301] Undefined identifier error dependent on order of imports when a circular import is involved

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Oct 3 08:28:19 PDT 2009


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


Rainer Schuetze <r.sagitario at gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #454 is|0                           |1
           obsolete|                            |


--- Comment #15 from Rainer Schuetze <r.sagitario at gmx.de> 2009-10-03 08:28:17 PDT ---
Created an attachment (id=469)
improved patch with version/debug support

I have improved the patch to look through version/debug conditionals, that
would bring back all the troubles if used for the imports.

I've also moved the setScope calls into the importAll functions, which was
already proposed in a comment nearby. At the same time, version/debug
conditional declarations pass the scope to its included branch.
StaticIfDeclarations cannot do this, because the semantic analysis is needed to
evaluate the condition.

In the long run, I'd propose to take the setScope mechanism further, setting
the scope as early as possible, allowing semantic analysis in arbitrary order.

I've run the qtd build with this patch and it still works. You'll also need the
patch of issue 3353 for the build to complete, though.

-- 
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