Ignore:
Timestamp:
Aug 10, 2010, 11:54:18 AM (14 years ago)
Author:
george
Message:

Added support for multiple source files and compilations for multiple modules in Project.pas

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/DelphiToC/Analyze/UParser.pas

    r53 r54  
    5454    procedure ParseUnit(SourceCode: TModule);
    5555    procedure ParseProgram(SourceCode: TModule);
    56     procedure ParseAll(SourceCode: TProgram);
    5756    procedure ParseCommonBlock(SourceCode: TCommonBlock; EndSymbol: char = ';');
    5857    function ParseCommand(SourceCode: TCommonBlock): TCommand;
     
    651650      ModuleType := mdProgram;
    652651      Expect(';');
    653     end
    654     else
    655       Name := '';
     652    end else Name := '';
    656653
    657654    // Uses section
     
    664661
    665662procedure TPascalParser.ParseUnit(SourceCode: TModule);
     663var
     664  NewModule: TModule;
    666665begin
    667666  Expect('unit');
    668   with TModule(ProgramCode.Modules[0]) do
     667  with Sourcecode do
    669668  begin
    670669    Name := ReadCode;
     
    677676
    678677{ TParserProgram }
    679 
    680 procedure TPascalParser.ParseAll(SourceCode: TProgram);
    681 var
    682   I: integer;
    683 begin
    684   with SourceCode do
    685   begin
    686     for I := 0 to Modules.Count - 1 do
    687       ParseModule(TModule(Modules[I]));
    688   end;
    689 end;
    690678
    691679{ TParserCommonBlock }
Note: See TracChangeset for help on using the changeset viewer.