* gimple-fold.c (can_refer_decl_in_current_unit_p): Default visibility is safe.

From-SVN: r207523
This commit is contained in:
Jan Hubicka 2014-02-05 20:42:37 +00:00
parent 7b1cd42745
commit a33a931b5f
1 changed files with 1 additions and 0 deletions

View File

@ -114,6 +114,7 @@ can_refer_decl_in_current_unit_p (tree decl, tree from_decl)
unit may be in separate DSO and the symbol may be hidden. */
if (DECL_VISIBILITY_SPECIFIED (decl)
&& DECL_EXTERNAL (decl)
&& DECL_VISIBILITY (decl) != VISIBILITY_DEFAULT
&& (!(snode = symtab_get_node (decl)) || !snode->in_other_partition))
return false;
/* When function is public, we always can introduce new reference.