summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-08-31 08:09:09 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-08-31 08:09:09 +0000
commite2ace509fc1205bed97a5114b13534610d4dbf5e (patch)
treecc45bac3595da32dd301fe705ac49fa65a1d2599 /tools
parent883f920acb6d347c2be0c937302d621ca21ec9dd (diff)
downloadllvm-e2ace509fc1205bed97a5114b13534610d4dbf5e.tar.gz
llvm-e2ace509fc1205bed97a5114b13534610d4dbf5e.tar.bz2
llvm-e2ace509fc1205bed97a5114b13534610d4dbf5e.tar.xz
llvm-mc: Simplify EmitAssignment ('.set' is identical to '=').
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80577 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/llvm-mc/AsmParser.cpp8
-rw-r--r--tools/llvm-mc/AsmParser.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/tools/llvm-mc/AsmParser.cpp b/tools/llvm-mc/AsmParser.cpp
index 0387857c24..dbceb6b98a 100644
--- a/tools/llvm-mc/AsmParser.cpp
+++ b/tools/llvm-mc/AsmParser.cpp
@@ -431,7 +431,7 @@ bool AsmParser::ParseStatement() {
// identifier '=' ... -> assignment statement
Lexer.Lex();
- return ParseAssignment(IDVal, false);
+ return ParseAssignment(IDVal);
default: // Normal instruction or directive.
break;
@@ -708,7 +708,7 @@ bool AsmParser::ParseStatement() {
return false;
}
-bool AsmParser::ParseAssignment(const StringRef &Name, bool IsDotSet) {
+bool AsmParser::ParseAssignment(const StringRef &Name) {
// FIXME: Use better location, we should use proper tokens.
SMLoc EqualLoc = Lexer.getLoc();
@@ -737,7 +737,7 @@ bool AsmParser::ParseAssignment(const StringRef &Name, bool IsDotSet) {
return Error(EqualLoc, "symbol has already been defined");
// Do the assignment.
- Out.EmitAssignment(Sym, Value, IsDotSet);
+ Out.EmitAssignment(Sym, Value);
return false;
}
@@ -769,7 +769,7 @@ bool AsmParser::ParseDirectiveSet() {
return TokError("unexpected token in '.set'");
Lexer.Lex();
- return ParseAssignment(Name, true);
+ return ParseAssignment(Name);
}
/// ParseDirectiveSection:
diff --git a/tools/llvm-mc/AsmParser.h b/tools/llvm-mc/AsmParser.h
index fda79ca842..7471a901a9 100644
--- a/tools/llvm-mc/AsmParser.h
+++ b/tools/llvm-mc/AsmParser.h
@@ -94,7 +94,7 @@ private:
SMLoc DirectiveLoc);
void EatToEndOfStatement();
- bool ParseAssignment(const StringRef &Name, bool IsDotSet);
+ bool ParseAssignment(const StringRef &Name);
bool ParsePrimaryExpr(const MCExpr *&Res);
bool ParseBinOpRHS(unsigned Precedence, const MCExpr *&Res);