[clang] [clang-tools-extra] [llvm] Add code completion for C++20 keywords. (PR #107982)

via cfe-commits cfe-commits at lists.llvm.org
Sat Oct 12 03:36:21 PDT 2024


================
@@ -460,6 +460,18 @@ Decl *Parser::ParseExportDeclaration() {
   assert(Tok.is(tok::kw_export));
   SourceLocation ExportLoc = ConsumeToken();
 
+  if (Tok.is(tok::code_completion)) {
+    cutOffParsing();
+    SemaCodeCompletion::ParserCompletionContext PCC;
+    if (PP.isIncrementalProcessingEnabled()) {
+      PCC = SemaCodeCompletion::PCC_TopLevelOrExpression;
+    } else {
+      PCC = SemaCodeCompletion::PCC_Namespace;
+    };
----------------
16bit-ykiko wrote:

Resolve.

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


More information about the cfe-commits mailing list