diff options
author | svenbarth <svenbarth@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2019-11-21 21:44:33 +0000 |
---|---|---|
committer | svenbarth <svenbarth@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2019-11-21 21:44:33 +0000 |
commit | cd322738f6bb485ca8cd84cd06b5a121068fdaa5 (patch) | |
tree | 2499175280782ebd8e262e7c96c52269a5fea1a8 /compiler/ncgld.pas | |
parent | 504a6c14b8b7301b1835c25f1a2adc5b4ce75a80 (diff) | |
download | fpc-cd322738f6bb485ca8cd84cd06b5a121068fdaa5.tar.gz |
* check the localswitches of the node instead of the global ones
git-svn-id: https://svn.freepascal.org/svn/fpc/trunk@43539 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'compiler/ncgld.pas')
-rw-r--r-- | compiler/ncgld.pas | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/ncgld.pas b/compiler/ncgld.pas index 2d01590dd8..ffd8dfdcf6 100644 --- a/compiler/ncgld.pas +++ b/compiler/ncgld.pas @@ -318,7 +318,7 @@ implementation ); indirect:=(tf_supports_packages in target_info.flags) and (target_info.system in systems_indirect_var_imports) and - (cs_imported_data in current_settings.localswitches) and + (cs_imported_data in localswitches) and not issystemunit; if not(vo_is_weak_external in gvs.varoptions) then reference_reset_symbol(tvref,current_asmdata.RefAsmSymbol(gvs.mangledname,AT_DATA,use_indirect_symbol(gvs)),0,sizeof(pint),[]) @@ -398,7 +398,7 @@ implementation (target_info.system in systems_indirect_var_imports) and (gvs.varoptions*[vo_is_external,vo_is_weak_external]=[]) and (gvs.owner.symtabletype in [globalsymtable,staticsymtable]) and - (cs_imported_data in current_settings.localswitches) and + (cs_imported_data in localswitches) and not sym_is_owned_by(gvs,current_module.globalsymtable) and ( (current_module.globalsymtable=current_module.localsymtable) or @@ -445,7 +445,7 @@ implementation location_reset_ref(location,LOC_CREFERENCE,def_cgsize(cansistringtype),cansistringtype.size,[]); indirect:=(tf_supports_packages in target_info.flags) and (target_info.system in systems_indirect_var_imports) and - (cs_imported_data in current_settings.localswitches) and + (cs_imported_data in localswitches) and (symtableentry.owner.moduleid<>current_module.moduleid); name:=make_mangledname('RESSTR',symtableentry.owner,symtableentry.name); location.reference.symbol:=current_asmdata.RefAsmSymbol(name,AT_DATA,indirect); @@ -1522,7 +1522,7 @@ implementation begin indirect := (tf_supports_packages in target_info.flags) and (target_info.system in systems_indirect_var_imports) and - (cs_imported_data in current_settings.localswitches) and + (cs_imported_data in localswitches) and (rttidef.owner.moduleid<>current_module.moduleid); location_reset_ref(location,LOC_CREFERENCE,OS_NO,sizeof(pint),[]); |