[PATCH] D85875: [OpenMP][FIX] Do not crash trying to print a missing (demangled) user condition

Alexey Bataev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 13 09:16:36 PDT 2020


ABataev added inline comments.


================
Comment at: clang/lib/AST/OpenMPClause.cpp:2204-2207
+        if (Selector.ScoreOrCondition)
+          Selector.ScoreOrCondition->printPretty(OS, nullptr, Policy);
+        else
+          OS << "...";
----------------
Why it can be `nullptr` if it is required to be set?


================
Comment at: clang/test/AST/ast-dump-openmp-begin-declare-variant_13.c:27-29
+// Make sure:
+//  - we do not see the ast nodes for the gpu kind
+//  - we do not choke on the text in the kind(fpga) guarded scopes
----------------
Does this comment match the test?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85875/new/

https://reviews.llvm.org/D85875



More information about the cfe-commits mailing list