mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-14 13:59:28 +02:00
Local symbols and defs that are needed for packages need to be registered as well => register the symbols and defs for the init and finalize functions.
pmodules.pas: * create_main_proc: register the proc's symbol ngenutil.pas, tnodeutils: * create_main_procdef: register the proc's def git-svn-id: trunk@33507 -
This commit is contained in:
parent
ea8322ee80
commit
e2b1f70ac6
@ -653,6 +653,8 @@ implementation
|
||||
pd:=cprocdef.create(main_program_level,true)
|
||||
else
|
||||
pd:=cprocdef.create(normal_function_level,true);
|
||||
{ always register the def }
|
||||
pd.register_def;
|
||||
pd.procsym:=ps;
|
||||
ps.ProcdefList.Add(pd);
|
||||
include(pd.procoptions,po_global);
|
||||
|
@ -605,6 +605,8 @@ implementation
|
||||
internalerror(200304275);
|
||||
{Generate a procsym for main}
|
||||
ps:=cprocsym.create('$'+name);
|
||||
{ always register the symbol }
|
||||
ps.register_sym;
|
||||
{ main are allways used }
|
||||
inc(ps.refs);
|
||||
st.insert(ps);
|
||||
|
Loading…
Reference in New Issue
Block a user