aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2011-04-29 17:53:11 +0000
committerDaniel Dunbar <daniel@zuster.org>2011-04-29 17:53:11 +0000
commit6db7fe873624dd5e5e21c263614df32577e40c95 (patch)
treed47554346cc8fe1a9e0d5ec5a676bf347c498be0
parentc003229ddc22cba38643f64341b53747bd5bc3fe (diff)
MC/AsmParser: Generalize a check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130515 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/MC/MCParser/AsmParser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/MC/MCParser/AsmParser.cpp b/lib/MC/MCParser/AsmParser.cpp
index d7ac5a70ed..d8fd27d873 100644
--- a/lib/MC/MCParser/AsmParser.cpp
+++ b/lib/MC/MCParser/AsmParser.cpp
@@ -1348,7 +1348,7 @@ bool AsmParser::ParseAssignment(StringRef Name, bool allow_redef) {
// FIXME: Diagnose assignment to protected identifier (e.g., register name).
if (Sym->isUndefined() && !Sym->isUsed() && !Sym->isVariable())
; // Allow redefinitions of undefined symbols only used in directives.
- else if (!Sym->isUndefined() && (!Sym->isAbsolute() || !allow_redef))
+ else if (!Sym->isUndefined() && (!Sym->isVariable() || !allow_redef))
return Error(EqualLoc, "redefinition of '" + Name + "'");
else if (!Sym->isVariable())
return Error(EqualLoc, "invalid assignment to '" + Name + "'");