Browse Source

enable typed addresses {$T+} in fpc and objfpc mode

git-svn-id: trunk@4795 -
micha 19 years ago
parent
commit
bd6afce618
1 changed files with 8 additions and 6 deletions
  1. 8 6
      compiler/scanner.pas

+ 8 - 6
compiler/scanner.pas

@@ -263,12 +263,14 @@ implementation
          if s='TP' then
          if s='TP' then
           aktmodeswitches:=tpmodeswitches
           aktmodeswitches:=tpmodeswitches
         else
         else
-         if s='FPC' then
-          aktmodeswitches:=fpcmodeswitches
-        else
-         if s='OBJFPC' then
-          aktmodeswitches:=objfpcmodeswitches
-        else
+         if s='FPC' then begin
+          aktmodeswitches:=fpcmodeswitches;
+          include(aktlocalswitches, cs_typed_addresses);
+        end else
+         if s='OBJFPC' then begin
+          aktmodeswitches:=objfpcmodeswitches;
+          include(aktlocalswitches, cs_typed_addresses);
+        end else
          if s='GPC' then
          if s='GPC' then
           aktmodeswitches:=gpcmodeswitches
           aktmodeswitches:=gpcmodeswitches
         else
         else