Forráskód Böngészése

* recognize MODE directive

git-svn-id: trunk@34690 -
michael 8 éve
szülő
commit
171ac5eebb
1 módosított fájl, 10 hozzáadás és 0 törlés
  1. 10 0
      packages/fcl-passrc/src/pscanner.pp

+ 10 - 0
packages/fcl-passrc/src/pscanner.pp

@@ -1808,6 +1808,16 @@ begin
                   exit;
                   end
                 end
+              else if (Directive = 'MODE')then
+                begin
+                Param:=UpperCase(Param);
+                // Eventually, we'll need to make the distinction...
+                // For now, treat OBJFPC as Delphi mode.
+                if (Param='DELPHI') or (Param='OBJFPC') then
+                  Options:=Options+[po_delphi]
+                else
+                  Options:=Options-[po_delphi]
+                end
               else if (Directive = 'DEFINE') then
                 HandleDefine(Param)
               else if (Directive = 'UNDEF') then