[Object] Fix a bug in a condition introduced in r226217 - visibility can't be

both hidden and default.

Bug found by inspection by Rafael Espindola. No test: As discussed in the commit
message for r226217 we don't have a good way to test this yet.

llvm-svn: 226869
This commit is contained in:
Lang Hames 2015-01-22 22:04:47 +00:00
parent df8b223dea
commit bd4ccc89e6

View File

@ -185,7 +185,7 @@ protected:
// visibility is either DEFAULT or PROTECTED. All other symbols are not
// exported.
if ((Binding == ELF::STB_GLOBAL || Binding == ELF::STB_WEAK) &&
(Visibility == ELF::STV_DEFAULT && Visibility == ELF::STV_PROTECTED))
(Visibility == ELF::STV_DEFAULT || Visibility == ELF::STV_PROTECTED))
return true;
return false;