[clang] [Clang][OpenMP] Validate prefer_type fr()/attr() arguments in append_args clause (PR #212307)
Zahira Ammarguellat via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 29 07:32:56 PDT 2026
================
@@ -7842,6 +7842,47 @@ SemaOpenMP::checkOpenMPDeclareVariantFunction(SemaOpenMP::DeclGroupPtrTy DG,
return std::make_pair(FD, cast<Expr>(DRE));
}
+/// Check prefer_type fr()/attr() arguments in an OMPInteropInfo for validity.
+/// Returns true if all arguments are valid; emits a diagnostic and returns
+/// false on the first invalid argument.
----------------
zahiraam wrote:
```suggestion
/// Validate prefer_type fr() and attr() arguments in an OMPInteropInfo.
/// fr() must be a string literal or constant integer expression.
/// attr() must be a string literal starting with "ompx_" and containing no commas.
/// Returns true if valid; emits diagnostic and returns false on first error.
```
https://github.com/llvm/llvm-project/pull/212307
More information about the cfe-commits
mailing list