Ignore:
Timestamp:
Jul 30, 2012, 3:52:56 PM (12 years ago)
Author:
chronos
Message:
  • Added: Addon modules support.
  • Modified: Restored usage of URegistry unit.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Compiler/Target/Delphi/UProducerPascal.pas

    r65 r68  
    1616  private
    1717    procedure GenerateUses(UsedModules: TUsedModuleList);
    18     procedure GenerateModule(Module: TModule);
    19     procedure GenerateUnit(Module: TModule);
    20     procedure GenerateLibrary(Module: TModule);
    21     procedure GeneratePackage(Module: TModule);
     18    procedure GenerateModule(Module: TSourceModule);
     19    procedure GenerateUnit(Module: TSourceModule);
     20    procedure GenerateLibrary(Module: TSourceModule);
     21    procedure GeneratePackage(Module: TSourceModule);
    2222    procedure GenerateType(AType: TType; AssignSymbol: Char = ':');
    2323    procedure GenerateTypes(Types: TTypeList);
     
    4343  public
    4444    procedure AssignToStringList(Target: TStringList); override;
    45     procedure Produce(Module: TModule); override;
     45    procedure Produce(Module: TSourceModule); override;
    4646    constructor Create;
    4747    destructor Destroy; override;
     
    9494end;
    9595
    96 procedure TProducerPascal.GenerateModule(Module: TModule);
     96procedure TProducerPascal.GenerateModule(Module: TSourceModule);
    9797begin
    9898  Module.TargetFile := Module.Name + '.pas';
     
    113113end;
    114114
    115 procedure TProducerPascal.GenerateUnit(Module: TModule);
     115procedure TProducerPascal.GenerateUnit(Module: TSourceModule);
    116116begin
    117117  EmitLn('unit ' + TModuleUnit(Module).Name + ';');
     
    127127end;
    128128
    129 procedure TProducerPascal.GenerateLibrary(Module: TModule);
    130 begin
    131 
    132 end;
    133 
    134 procedure TProducerPascal.GeneratePackage(Module: TModule);
     129procedure TProducerPascal.GenerateLibrary(Module: TSourceModule);
     130begin
     131
     132end;
     133
     134procedure TProducerPascal.GeneratePackage(Module: TSourceModule);
    135135begin
    136136
     
    196196end;
    197197
    198 procedure TProducerPascal.Produce(Module: TModule);
     198procedure TProducerPascal.Produce(Module: TSourceModule);
    199199var
    200200  I: Integer;
     
    206206  with Module.ParentProgram do
    207207  for I := 0 to Modules.Count - 1 do
    208     if TModule(Modules[I]).Name = 'System' then
    209       TModule(Modules[I]).Name := 'System2';
     208    if TSourceModule(Modules[I]).Name = 'System' then
     209      TSourceModule(Modules[I]).Name := 'System2';
    210210
    211211  GenerateModule(Module);
Note: See TracChangeset for help on using the changeset viewer.