[PATCH] D111854: [OPENMP51]Initial parsing/sema for append_args clause for 'declare variant'
Alexey Bataev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 21 04:39:55 PDT 2021
ABataev added inline comments.
================
Comment at: clang/include/clang/Parse/Parser.h:3209
+ /// Parse an 'append_args' clause for '#pragma omp declare variant'.
+ bool ParseOpenMPAppendArgs(
+ SmallVectorImpl<OMPDeclareVariantAttr::InteropType> &InterOpTypes);
----------------
`parseOpenMPAppendArgs`
================
Comment at: clang/lib/Parse/ParseOpenMP.cpp:1493
+/// value pair when a valid list is specified.
+static llvm::Optional<std::pair<bool, bool>> parseInteropTypeList(Parser &P) {
+ const Token &Tok = P.getCurToken();
----------------
Better to introduce an enum here and return it as a result. Or return `Optional<OMPDeclareVariantAttr::InteropType>`
================
Comment at: clang/test/OpenMP/declare_variant_clauses_messages.cpp:17
int Other;
void foo_v1(float *AAA, float *BBB, int *I) { return; }
----------------
Add (a) test(s) for varargs functions. Also, what about templates, member functions, static member functions, virtual functions, pure virtual functions?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111854/new/
https://reviews.llvm.org/D111854
More information about the llvm-commits
mailing list