aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/MC')
-rw-r--r--llvm/lib/MC/MCParser/AsmLexer.cpp1
-rw-r--r--llvm/lib/MC/MCParser/AsmParser.cpp10
-rw-r--r--llvm/lib/MC/MCParser/MasmParser.cpp10
3 files changed, 8 insertions, 13 deletions
diff --git a/llvm/lib/MC/MCParser/AsmLexer.cpp b/llvm/lib/MC/MCParser/AsmLexer.cpp
index a6188f0..1af4a29 100644
--- a/llvm/lib/MC/MCParser/AsmLexer.cpp
+++ b/llvm/lib/MC/MCParser/AsmLexer.cpp
@@ -16,7 +16,6 @@
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/MC/MCAsmInfo.h"
-#include "llvm/MC/MCParser/AsmLexer.h"
#include "llvm/Support/Compiler.h"
#include "llvm/Support/SMLoc.h"
#include "llvm/Support/SaveAndRestore.h"
diff --git a/llvm/lib/MC/MCParser/AsmParser.cpp b/llvm/lib/MC/MCParser/AsmParser.cpp
index dd1bc2b..3c9ab8e 100644
--- a/llvm/lib/MC/MCParser/AsmParser.cpp
+++ b/llvm/lib/MC/MCParser/AsmParser.cpp
@@ -228,11 +228,9 @@ public:
AssemblerDialect = i;
}
- void Note(SMLoc L, const Twine &Msg, SMRange Range = std::nullopt) override;
- bool Warning(SMLoc L, const Twine &Msg,
- SMRange Range = std::nullopt) override;
- bool printError(SMLoc L, const Twine &Msg,
- SMRange Range = std::nullopt) override;
+ void Note(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
+ bool Warning(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
+ bool printError(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
const AsmToken &Lex() override;
@@ -312,7 +310,7 @@ private:
void printMacroInstantiations();
void printMessage(SMLoc Loc, SourceMgr::DiagKind Kind, const Twine &Msg,
- SMRange Range = std::nullopt) const {
+ SMRange Range = {}) const {
ArrayRef<SMRange> Ranges(Range);
SrcMgr.PrintMessage(Loc, Kind, Msg, Ranges);
}
diff --git a/llvm/lib/MC/MCParser/MasmParser.cpp b/llvm/lib/MC/MCParser/MasmParser.cpp
index 8a8f111..3462954 100644
--- a/llvm/lib/MC/MCParser/MasmParser.cpp
+++ b/llvm/lib/MC/MCParser/MasmParser.cpp
@@ -483,11 +483,9 @@ public:
AssemblerDialect = i;
}
- void Note(SMLoc L, const Twine &Msg, SMRange Range = std::nullopt) override;
- bool Warning(SMLoc L, const Twine &Msg,
- SMRange Range = std::nullopt) override;
- bool printError(SMLoc L, const Twine &Msg,
- SMRange Range = std::nullopt) override;
+ void Note(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
+ bool Warning(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
+ bool printError(SMLoc L, const Twine &Msg, SMRange Range = {}) override;
enum ExpandKind { ExpandMacros, DoNotExpandMacros };
const AsmToken &Lex(ExpandKind ExpandNextToken);
@@ -592,7 +590,7 @@ private:
bool expandStatement(SMLoc Loc);
void printMessage(SMLoc Loc, SourceMgr::DiagKind Kind, const Twine &Msg,
- SMRange Range = std::nullopt) const {
+ SMRange Range = {}) const {
ArrayRef<SMRange> Ranges(Range);
SrcMgr.PrintMessage(Loc, Kind, Msg, Ranges);
}