diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2013-05-13 00:12:11 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2013-05-13 00:12:11 +0000 |
commit | 3ae00052cd260a7ed753ec2e1338d22119d25595 (patch) | |
tree | d9bc7cf2ffc60eba2f2ccaf8d6c08f5d2a9d908f /clang/lib/CodeGen/CGVTables.cpp | |
parent | 0e4676e1f53b7a463cc4c4e9af87ee91c86d2a62 (diff) | |
download | llvm-3ae00052cd260a7ed753ec2e1338d22119d25595.zip llvm-3ae00052cd260a7ed753ec2e1338d22119d25595.tar.gz llvm-3ae00052cd260a7ed753ec2e1338d22119d25595.tar.bz2 |
Cleanup handling of UniqueExternalLinkage.
This patch renames getLinkage to getLinkageInternal. Only code that
needs to handle UniqueExternalLinkage specially should call this.
Linkage, as defined in the c++ standard, is provided by
getFormalLinkage. It maps UniqueExternalLinkage to ExternalLinkage.
Most places in the compiler actually want isExternallyVisible, which
handles UniqueExternalLinkage as internal.
llvm-svn: 181677
Diffstat (limited to 'clang/lib/CodeGen/CGVTables.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGVTables.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGVTables.cpp b/clang/lib/CodeGen/CGVTables.cpp index 069cd5f..9a345cf 100644 --- a/clang/lib/CodeGen/CGVTables.cpp +++ b/clang/lib/CodeGen/CGVTables.cpp @@ -719,7 +719,7 @@ CodeGenVTables::GenerateConstructionVTable(const CXXRecordDecl *RD, /// Note that we only call this at the end of the translation unit. llvm::GlobalVariable::LinkageTypes CodeGenModule::getVTableLinkage(const CXXRecordDecl *RD) { - if (RD->getLinkage() != ExternalLinkage) + if (!RD->isExternallyVisible()) return llvm::GlobalVariable::InternalLinkage; // We're at the end of the translation unit, so the current key |