Sfoglia il codice sorgente

pkgutil.pas:
* exportabstractrecordsymproc & insert_export: don't try to export a typedef if it doesn't belong to the current symtable, happens for cross unit type aliases

git-svn-id: branches/svenbarth/packages@32635 -

svenbarth 9 anni fa
parent
commit
8ba8d91434
1 ha cambiato i file con 6 aggiunte e 0 eliminazioni
  1. 6 0
      compiler/pkgutil.pas

+ 6 - 0
compiler/pkgutil.pas

@@ -114,6 +114,9 @@ implementation
                   { don't export generics or their nested types }
                   if df_generic in def.defoptions then
                     exit;
+                  { for cross unit type aliases this might happen }
+                  if def.owner<>tsymtable(arg) then
+                    exit;
                   def.symtable.symlist.foreachcall(@exportabstractrecordsymproc,def.symtable);
                 end;
             end;
@@ -160,6 +163,9 @@ implementation
                   def:=tabstractrecorddef(ttypesym(sym).typedef);
                   if def.is_generic then
                     exit;
+                  { for cross unit type aliases this might happen }
+                  if def.owner<>tsymtable(arg) then
+                    exit;
                   def.symtable.SymList.ForEachCall(@exportabstractrecordsymproc,def.symtable);
                   if (def.typ=objectdef) and (oo_has_vmt in tobjectdef(def).objectoptions) then
                     begin