aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2013-04-04 16:43:41 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2013-04-04 16:43:41 +0000
commitba2bfa07cbcb088e3afc5565a3b301a7873771a3 (patch)
treeeca56e0dacb92c09d1c5791f093d503e51483441 /lib/Sema/SemaDecl.cpp
parent32d2a6528c395e52914df51f25af13cafaace8dd (diff)
Fix a recent linkage regression.
Now that we don't have a semantic storage class, use the linkage. Thanks to Bruce Stephens for reporting this. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178766 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDecl.cpp')
-rw-r--r--lib/Sema/SemaDecl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp
index 436fca35cb..af0b2bb72c 100644
--- a/lib/Sema/SemaDecl.cpp
+++ b/lib/Sema/SemaDecl.cpp
@@ -2328,7 +2328,7 @@ bool Sema::MergeFunctionDecl(FunctionDecl *New, Decl *OldD, Scope *S) {
// storage classes.
if (!isa<CXXMethodDecl>(New) && !isa<CXXMethodDecl>(Old) &&
New->getStorageClass() == SC_Static &&
- Old->getStorageClass() != SC_Static &&
+ Old->hasExternalLinkage() &&
!New->getTemplateSpecializationInfo() &&
!canRedefineFunction(Old, getLangOpts())) {
if (getLangOpts().MicrosoftExt) {