[PATCH] D78160: [flang] Checks for constraints C741 through C750
Steve Scalpone via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 14 17:25:49 PDT 2020
sscalpone added inline comments.
================
Comment at: flang/lib/Evaluate/check-expression.cpp:248
+ "rank same_type_as shape size storage_size tiny ubound ucobound"};
+ if (inquiryIntrinsics.find(intrin.name) != std::string::npos &&
+ !IsConstantExpr(x)) {
----------------
tskeith wrote:
> This test and the one above only work if there are no other intrinsics that can be returned by `GetSpecificIntrinsic` whose names are not substrings of one of the names in the string. For example, if `intrin.name` is "max", it will find it in `inquiryIntrinsics`.
>
> It seems like a set would be a better representation than a string. Or maybe an addition to the intrinsics table?
+1 an addition to the intrinsics table
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78160/new/
https://reviews.llvm.org/D78160
More information about the llvm-commits
mailing list