mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-07 16:28:22 +02:00
* Use IncRefCountBy
git-svn-id: trunk@6142 -
This commit is contained in:
parent
0cfa2a6aad
commit
f82d47e370
@ -258,7 +258,7 @@ implementation
|
||||
end;
|
||||
staticvarsym :
|
||||
begin
|
||||
inc(tabstractvarsym(symtableentry).refs);
|
||||
tabstractvarsym(symtableentry).IncRefCountBy(1);
|
||||
{ static variables referenced in procedures or from finalization,
|
||||
variable needs to be in memory.
|
||||
It is too hard and the benefit is too small to detect whether a
|
||||
@ -275,7 +275,7 @@ implementation
|
||||
paravarsym,
|
||||
localvarsym :
|
||||
begin
|
||||
inc(tabstractvarsym(symtableentry).refs);
|
||||
tabstractvarsym(symtableentry).IncRefCountBy(1);
|
||||
{ Nested variable? The we need to load the framepointer of
|
||||
the parent procedure }
|
||||
if assigned(current_procinfo) and
|
||||
@ -393,7 +393,7 @@ implementation
|
||||
Tabstractvarsym(symtableentry).trigger_notifications(vn_onread);
|
||||
{ count variable references }
|
||||
if cg.t_times>1 then
|
||||
inc(tabstractvarsym(symtableentry).refs,cg.t_times-1);
|
||||
tabstractvarsym(symtableentry).IncRefCountBy(cg.t_times-1);
|
||||
end;
|
||||
procsym :
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user