|
@@ -41,6 +41,7 @@ unit scandir;
|
|
setalloc,
|
|
setalloc,
|
|
packenum,
|
|
packenum,
|
|
packrecords : shortint;
|
|
packrecords : shortint;
|
|
|
|
+ asmmode : tasmmode;
|
|
end;
|
|
end;
|
|
|
|
|
|
type
|
|
type
|
|
@@ -312,16 +313,19 @@ unit scandir;
|
|
procedure dir_asmmode;
|
|
procedure dir_asmmode;
|
|
var
|
|
var
|
|
s : string;
|
|
s : string;
|
|
|
|
+ asmmode: tasmmode;
|
|
begin
|
|
begin
|
|
current_scanner.skipspace;
|
|
current_scanner.skipspace;
|
|
s:=current_scanner.readid;
|
|
s:=current_scanner.readid;
|
|
If Inside_asm_statement then
|
|
If Inside_asm_statement then
|
|
Message1(scan_w_no_asm_reader_switch_inside_asm,s);
|
|
Message1(scan_w_no_asm_reader_switch_inside_asm,s);
|
|
if s='DEFAULT' then
|
|
if s='DEFAULT' then
|
|
- current_settings.asmmode:=init_settings.asmmode
|
|
|
|
|
|
+ recordpendingasmmode(init_settings.asmmode)
|
|
else
|
|
else
|
|
- if not SetAsmReadMode(s,current_settings.asmmode) then
|
|
|
|
- Message1(scan_e_illegal_asmmode_specifier,s);
|
|
|
|
|
|
+ if not SetAsmReadMode(s,asmmode) then
|
|
|
|
+ Message1(scan_e_illegal_asmmode_specifier,s)
|
|
|
|
+ else
|
|
|
|
+ recordpendingasmmode(asmmode);
|
|
end;
|
|
end;
|
|
|
|
|
|
{$if defined(m68k) or defined(arm)}
|
|
{$if defined(m68k) or defined(arm)}
|
|
@@ -1263,6 +1267,7 @@ unit scandir;
|
|
recordpendingpackenum(switchesstatestack[switchesstatestackpos].packenum);
|
|
recordpendingpackenum(switchesstatestack[switchesstatestackpos].packenum);
|
|
recordpendingpackrecords(switchesstatestack[switchesstatestackpos].packrecords);
|
|
recordpendingpackrecords(switchesstatestack[switchesstatestackpos].packrecords);
|
|
recordpendingsetalloc(switchesstatestack[switchesstatestackpos].setalloc);
|
|
recordpendingsetalloc(switchesstatestack[switchesstatestackpos].setalloc);
|
|
|
|
+ recordpendingasmmode(switchesstatestack[switchesstatestackpos].asmmode);
|
|
pendingstate.nextmessagerecord:=switchesstatestack[switchesstatestackpos].pmessage;
|
|
pendingstate.nextmessagerecord:=switchesstatestack[switchesstatestackpos].pmessage;
|
|
{ flushpendingswitchesstate will reset the message state }
|
|
{ flushpendingswitchesstate will reset the message state }
|
|
current_settings.pmessage:=nil;
|
|
current_settings.pmessage:=nil;
|
|
@@ -1327,6 +1332,11 @@ unit scandir;
|
|
else
|
|
else
|
|
switchesstatestack[switchesstatestackpos].setalloc:=current_settings.setalloc;
|
|
switchesstatestack[switchesstatestackpos].setalloc:=current_settings.setalloc;
|
|
|
|
|
|
|
|
+ if psf_asmmode_changed in pendingstate.flags then
|
|
|
|
+ switchesstatestack[switchesstatestackpos].asmmode:=pendingstate.nextasmmode
|
|
|
|
+ else
|
|
|
|
+ switchesstatestack[switchesstatestackpos].asmmode:=current_settings.asmmode;
|
|
|
|
+
|
|
switchesstatestack[switchesstatestackpos].pmessage:=pendingstate.nextmessagerecord;
|
|
switchesstatestack[switchesstatestackpos].pmessage:=pendingstate.nextmessagerecord;
|
|
Inc(switchesstatestackpos);
|
|
Inc(switchesstatestackpos);
|
|
end;
|
|
end;
|