summaryrefslogtreecommitdiffstats
path: root/lib/AsmParser/LLLexer.cpp
diff options
context:
space:
mode:
authorrdivacky <rdivacky@FreeBSD.org>2010-01-01 10:31:22 +0000
committerrdivacky <rdivacky@FreeBSD.org>2010-01-01 10:31:22 +0000
commita16c51cee9225a354c999dd1076d5dba2aa79807 (patch)
treedba00119388b84f9f44e6ec5e9129f807fd79ca3 /lib/AsmParser/LLLexer.cpp
parent40a6fcdb85efd93fe0e36c9552cfb0b18b5eacd6 (diff)
downloadFreeBSD-src-a16c51cee9225a354c999dd1076d5dba2aa79807.zip
FreeBSD-src-a16c51cee9225a354c999dd1076d5dba2aa79807.tar.gz
Update LLVM to 92395.
Diffstat (limited to 'lib/AsmParser/LLLexer.cpp')
-rw-r--r--lib/AsmParser/LLLexer.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/AsmParser/LLLexer.cpp b/lib/AsmParser/LLLexer.cpp
index cad1d3b..8ad658d 100644
--- a/lib/AsmParser/LLLexer.cpp
+++ b/lib/AsmParser/LLLexer.cpp
@@ -254,7 +254,7 @@ lltok::Kind LLLexer::LexToken() {
case ';':
SkipLineComment();
return LexToken();
- case '!': return LexMetadata();
+ case '!': return LexExclaim();
case '0': case '1': case '2': case '3': case '4':
case '5': case '6': case '7': case '8': case '9':
case '-':
@@ -422,11 +422,11 @@ static bool JustWhitespaceNewLine(const char *&Ptr) {
return false;
}
-/// LexMetadata:
-/// !{...}
-/// !42
+/// LexExclaim:
/// !foo
-lltok::Kind LLLexer::LexMetadata() {
+/// !
+lltok::Kind LLLexer::LexExclaim() {
+ // Lex a metadata name as a MetadataVar.
if (isalpha(CurPtr[0])) {
++CurPtr;
while (isalnum(CurPtr[0]) || CurPtr[0] == '-' || CurPtr[0] == '$' ||
@@ -434,9 +434,9 @@ lltok::Kind LLLexer::LexMetadata() {
++CurPtr;
StrVal.assign(TokStart+1, CurPtr); // Skip !
- return lltok::NamedOrCustomMD;
+ return lltok::MetadataVar;
}
- return lltok::Metadata;
+ return lltok::exclaim;
}
/// LexIdentifier: Handle several related productions:
OpenPOWER on IntegriCloud