mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-09 12:46:27 +02:00
* properly align case target labels
git-svn-id: trunk@6395 -
This commit is contained in:
parent
530d5c125d
commit
c5d56702ff
@ -891,6 +891,7 @@ implementation
|
|||||||
{ generate the instruction blocks }
|
{ generate the instruction blocks }
|
||||||
for i:=0 to blocks.count-1 do
|
for i:=0 to blocks.count-1 do
|
||||||
begin
|
begin
|
||||||
|
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||||
cg.a_label(current_asmdata.CurrAsmList,pcaseblock(blocks[i])^.blocklabel);
|
cg.a_label(current_asmdata.CurrAsmList,pcaseblock(blocks[i])^.blocklabel);
|
||||||
secondpass(pcaseblock(blocks[i])^.statement);
|
secondpass(pcaseblock(blocks[i])^.statement);
|
||||||
{ don't come back to case line }
|
{ don't come back to case line }
|
||||||
@ -900,6 +901,7 @@ implementation
|
|||||||
{$endif OLDREGVARS}
|
{$endif OLDREGVARS}
|
||||||
cg.a_jmp_always(current_asmdata.CurrAsmList,endlabel);
|
cg.a_jmp_always(current_asmdata.CurrAsmList,endlabel);
|
||||||
end;
|
end;
|
||||||
|
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||||
{ ...and the else block }
|
{ ...and the else block }
|
||||||
cg.a_label(current_asmdata.CurrAsmList,elselabel);
|
cg.a_label(current_asmdata.CurrAsmList,elselabel);
|
||||||
if assigned(elseblock) then
|
if assigned(elseblock) then
|
||||||
@ -909,6 +911,7 @@ implementation
|
|||||||
load_all_regvars(current_asmdata.CurrAsmList);
|
load_all_regvars(current_asmdata.CurrAsmList);
|
||||||
{$endif OLDREGVARS}
|
{$endif OLDREGVARS}
|
||||||
end;
|
end;
|
||||||
|
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||||
cg.a_label(current_asmdata.CurrAsmList,endlabel);
|
cg.a_label(current_asmdata.CurrAsmList,endlabel);
|
||||||
|
|
||||||
{ Reset labels }
|
{ Reset labels }
|
||||||
|
Loading…
Reference in New Issue
Block a user