From eb9e5f081cbae5d122c7db4812d1f760f6c8c43f Mon Sep 17 00:00:00 2001 From: Colin LeMahieu Date: Mon, 10 Aug 2015 19:58:06 +0000 Subject: [PATCH] [TableGen] NFC improving comments about what the tokenized identifiers will contain. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244493 91177308-0d34-0410-b5e6-96231b3b80d8 --- utils/TableGen/AsmMatcherEmitter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/TableGen/AsmMatcherEmitter.cpp b/utils/TableGen/AsmMatcherEmitter.cpp index d4a0616584b..8403aa56556 100644 --- a/utils/TableGen/AsmMatcherEmitter.cpp +++ b/utils/TableGen/AsmMatcherEmitter.cpp @@ -884,12 +884,13 @@ void MatchableInfo::tokenizeAsmString(const AsmMatcherInfo &Info) { InTok = false; } - // If this isn't "${", treat like a normal token. + // If this isn't "${", start new identifier looking like "$xxx" if (i + 1 == String.size() || String[i + 1] != '{') { Prev = i; break; } + // If this is "${" find the next "}" and make an identifier like "${xxx}" StringRef::iterator End = std::find(String.begin() + i, String.end(),'}'); assert(End != String.end() && "Missing brace in operand reference!"); size_t EndPos = End - String.begin(); -- 2.34.1