[llvm] [LLVM][AsmParser] Add support for C style comments (PR #111554)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 1 09:42:27 PDT 2024


================
@@ -251,6 +258,12 @@ lltok::Kind LLLexer::LexToken() {
     case ',': return lltok::comma;
     case '*': return lltok::star;
     case '|': return lltok::bar;
+    case '/':
+      if (peekNextChar() != '*')
----------------
nikic wrote:

With the new implementation, can't you use getNextChar() directly here, thus making the changes to extract peekNextChar() unnecessary?

https://github.com/llvm/llvm-project/pull/111554


More information about the llvm-commits mailing list