Browse Source

* Make sure webcompiler works again

Michaël Van Canneyt 3 years ago
parent
commit
050153fb50
2 changed files with 6 additions and 2 deletions
  1. 4 0
      packages/fcl-passrc/src/pparser.pp
  2. 2 2
      utils/pas2js/pas2jswebcompiler.pp

+ 4 - 0
packages/fcl-passrc/src/pparser.pp

@@ -509,8 +509,10 @@ Function IsHintToken(T : String; Out AHint : TPasMemberHint) : boolean;
 Function IsProcModifier(S : String; Out PM : TProcedureModifier) : Boolean;
 Function IsCallingConvention(S : String; out CC : TCallingConvention) : Boolean;
 Function TokenToAssignKind( tk : TToken) : TAssignKind;
+{$ifndef pas2js}
 procedure ReadNextPascalToken(var Position: PChar; out TokenStart: PChar;
   NestedComments: boolean; SkipDirectives: boolean);
+{$endif}
 
 implementation
 
@@ -678,6 +680,7 @@ begin
   end;
 end;
 
+{$ifndef pas2js}
 procedure ReadNextPascalToken(var Position: PChar; out TokenStart: PChar;
   NestedComments: boolean; SkipDirectives: boolean);
 const
@@ -943,6 +946,7 @@ begin
   end;
   Position:=Src;
 end;
+{$endif}
 
 function ParseSource(AEngine: TPasTreeContainer;
   const FPCCommandLine, OSTarget, CPUTarget: String): TPasModule;

+ 2 - 2
utils/pas2js/pas2jswebcompiler.pp

@@ -15,7 +15,7 @@ Type
   private
     function GetWebFS: TPas2JSWebFS;
   Protected
-    function DoWriteJSFile(const DestFilename: String; aWriter: TPas2JSMapper): Boolean; override;
+    function DoWriteJSFile(const DestFilename, DestMapFile: String; aWriter: TPas2JSMapper): Boolean; override;
     function CreateSetOfCompilerFiles(keyType: TKeyCompareType): TPasAnalyzerKeySet; override;
     function CreateFS : TPas2JSFS; override;
   Public
@@ -62,7 +62,7 @@ begin
   Result:=TPas2JSWebFS(FS)
 end;
 
-function TPas2JSWebcompiler.DoWriteJSFile(const DestFilename: String; aWriter: TPas2JSMapper): Boolean;
+function TPas2JSWebcompiler.DoWriteJSFile(const DestFilename, DestMapFile: String; aWriter: TPas2JSMapper): Boolean;
 
 Var
   S : String;