--- Comment #13 from Eldar Insafutdinov <e.insafutdi...@gmail.com> 2009-09-19
13:37:03 PDT ---
(In reply to comment #12)
> Created an attachment (id=454) [details]
> do all imports before semantic analysis
> Having done some investigation of the deferred semantic analysis mechanism, it
> might be best to try to keep its usage to a minimum, because it might have a
> negative impact on compilation speed and memory consumption. So my patch is
> probably not so bad after all.
> Some details:
> The problem is that, though the files are parsed, their symbol table might not
> yet hold any identifiers, because the semantic analysis has not been run on
> So I introduced another compile step after parsing, but before the semantic
> analysis. The files on the command line are scanned for import statements,
> loading and parsing the referenced modules and applying the same process on
> these files. In the same step, the global members of the module are added to
> the modules' symbol table (this has been moved from the semantic analysis).
> The import statements must not be conditional, because the semantic analysis
> needed to evaluate a "static if" statement. If the semantic analysis gets to
> the import statement, the additional compile step kicks in again for any
> not already loaded.
> This patch also fixes bugs #3286, #1592 and #258
Your patch applied against dmd 1.047 fixes the issue with building both gtkD
and QtD. It would be cool if it were included in the upstream.
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------