mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-12-16 04:30:35 +01:00
* don't create the nestedvars struct for pure assembler routines, as
those will never call a nested routine using Pascal-level support
for accessing local variables (even if the nestedvars stayed empty,
this caused a stack frame to be allocated because a temp of 0
bytes is rounded up to 4 bytes)
git-svn-id: trunk@32739 -
This commit is contained in:
parent
aef6120438
commit
5a8c151a72
@ -1166,13 +1166,16 @@ implementation
|
||||
symtablestack.free;
|
||||
symtablestack:=old_symtablestack.getcopyuntil(pd.localst);
|
||||
pnestedvarsdef:=cpointerdef.getreusable(nestedvarsdef);
|
||||
nestedvars:=clocalvarsym.create('$nestedvars',vs_var,nestedvarsdef,[],true);
|
||||
pd.localst.insert(nestedvars);
|
||||
pd.parentfpstruct:=nestedvars;
|
||||
if not(po_assembler in pd.procoptions) then
|
||||
begin
|
||||
nestedvars:=clocalvarsym.create('$nestedvars',vs_var,nestedvarsdef,[],true);
|
||||
pd.localst.insert(nestedvars);
|
||||
pd.parentfpstruct:=nestedvars;
|
||||
pd.parentfpinitblock:=cblocknode.create(nil);
|
||||
end;
|
||||
symtablestack.free;
|
||||
pd.parentfpstructptrtype:=pnestedvarsdef;
|
||||
|
||||
pd.parentfpinitblock:=cblocknode.create(nil);
|
||||
symtablestack.free;
|
||||
symtablestack:=old_symtablestack;
|
||||
end;
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user