瀏覽代碼

* don't export types that have been merely renamed (and thus are part of another unit and potentially another package altogether)

git-svn-id: trunk@34340 -
svenbarth 9 年之前
父節點
當前提交
f1cdb5c4e9
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      compiler/pkgutil.pas

+ 4 - 1
compiler/pkgutil.pas

@@ -168,7 +168,10 @@ implementation
 
   procedure export_typedef(def:tdef;symtable:tsymtable;global:boolean);
     begin
-      if not (global or is_class(def)) or (df_internal in def.defoptions) then
+      if not (global or is_class(def)) or
+          (df_internal in def.defoptions) or
+          { happens with type renaming declarations ("abc = xyz") }
+          (def.owner<>symtable) then
         exit;
       if ds_rtti_table_written in def.defstates then
         exportname(def.rtti_mangledname(fullrtti));