* moved deref to be done after loading of implementation units. prederef

is still done directly after loading of symbols and definitions.
This commit is contained in:
peter 2001-02-21 19:37:19 +00:00
parent db0fc0ac36
commit 8acb794be6
2 changed files with 24 additions and 9 deletions

View File

@ -408,6 +408,8 @@ implementation
end;
pu:=tused_unit(pu.next);
end;
{ deref }
punitsymtable(current_module.globalsymtable)^.deref;
{ load browser info if stored }
if ((current_module.flags and uf_has_browser)<>0) and load_refs then
punitsymtable(current_module.globalsymtable)^.load_symtable_refs;
@ -1625,7 +1627,11 @@ implementation
end.
{
$Log$
Revision 1.21 2001-01-14 22:13:52 peter
Revision 1.22 2001-02-21 19:37:19 peter
* moved deref to be done after loading of implementation units. prederef
is still done directly after loading of symbols and definitions.
Revision 1.21 2001/01/14 22:13:52 peter
* fixed crash with program name as a important unit name
Revision 1.20 2000/12/25 00:07:27 peter

View File

@ -52,6 +52,7 @@ interface
procedure loadsyms;
procedure writedefs;
procedure writesyms;
procedure prederef;
procedure deref;
procedure insert(sym : psymentry);virtual;
procedure insert_in(psymt : psymtable;offset : longint);
@ -237,11 +238,6 @@ implementation
pstoredsym(sym)^.write_references;
end;
procedure derefsym(p : pnamedindexobject);
begin
psym(p)^.deref;
end;
procedure check_forward(sym : pnamedindexobject);
begin
if psym(sym)^.typ=procsym then
@ -736,7 +732,7 @@ implementation
end;
procedure tstoredsymtable.deref;
procedure tstoredsymtable.prederef;
var
hp : pdef;
hs : psym;
@ -748,6 +744,14 @@ implementation
hs^.prederef;
hs:=psym(hs^.indexnext);
end;
end;
procedure tstoredsymtable.deref;
var
hp : pdef;
hs : psym;
begin
{ deref the definitions }
hp:=pdef(defindex^.first);
while assigned(hp) do
@ -764,6 +768,7 @@ implementation
end;
end;
{ this procedure is reserved for inserting case variant into
a record symtable }
{ the offset is the location of the start of the variant
@ -876,7 +881,7 @@ implementation
if not (typ in [localsymtable,parasymtable,recordsymtable,objectsymtable]) then
begin
{ now we can deref the syms and defs }
deref;
prederef;
{ restore symtablestack }
symtablestack:=next;
end;
@ -2369,7 +2374,11 @@ implementation
end.
{
$Log$
Revision 1.25 2001-02-20 21:41:16 peter
Revision 1.26 2001-02-21 19:37:19 peter
* moved deref to be done after loading of implementation units. prederef
is still done directly after loading of symbols and definitions.
Revision 1.25 2001/02/20 21:41:16 peter
* new fixfilename, findfile for unix. Look first for lowercase, then
NormalCase and last for UPPERCASE names.