summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2012-01-10 18:26:14 +0000
committerChandler Carruth <chandlerc@gmail.com>2012-01-10 18:26:14 +0000
commitbfe8ecd347ece1ee223f929d3adbab455f6af5ba (patch)
treed27be3058aeae086284ae353e001260745c34d04 /clang
parent4c0ee749bb3fb5f6912e1f8e7ac45615b6ba8592 (diff)
downloadbcm5719-llvm-bfe8ecd347ece1ee223f929d3adbab455f6af5ba.tar.gz
bcm5719-llvm-bfe8ecd347ece1ee223f929d3adbab455f6af5ba.zip
Remove a set, but unused variable. Found with GCC's warning.
llvm-svn: 147864
Diffstat (limited to 'clang')
-rw-r--r--clang/lib/Sema/SemaDeclCXX.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/clang/lib/Sema/SemaDeclCXX.cpp b/clang/lib/Sema/SemaDeclCXX.cpp
index 0ca75df591e..39f79757be3 100644
--- a/clang/lib/Sema/SemaDeclCXX.cpp
+++ b/clang/lib/Sema/SemaDeclCXX.cpp
@@ -5532,7 +5532,6 @@ Decl *Sema::ActOnStartNamespaceDef(Scope *NamespcScope,
// For anonymous namespace, take the location of the left brace.
SourceLocation Loc = II ? IdentLoc : LBrace;
bool IsInline = InlineLoc.isValid();
- bool IsInvalid = false;
bool IsStd = false;
bool AddToKnown = false;
Scope *DeclRegionScope = NamespcScope->getParent();
@@ -5587,7 +5586,6 @@ Decl *Sema::ActOnStartNamespaceDef(Scope *NamespcScope,
Diag(Loc, diag::err_redefinition_different_kind)
<< II;
Diag(PrevDecl->getLocation(), diag::note_previous_definition);
- IsInvalid = true;
// Continue on to push Namespc as current DeclContext and return it.
} else if (II->isStr("std") &&
CurContext->getRedeclContext()->isTranslationUnit()) {
@@ -5617,8 +5615,7 @@ Decl *Sema::ActOnStartNamespaceDef(Scope *NamespcScope,
Diag(Loc, diag::err_inline_namespace_mismatch)
<< IsInline;
Diag(PrevNS->getLocation(), diag::note_previous_definition);
- IsInvalid = true;
-
+
// Recover by ignoring the new namespace's inline status.
IsInline = PrevNS->isInline();
}
OpenPOWER on IntegriCloud