[flang-commits] [flang] [flang] Error out when assumed rank variable in used as selector in SELECT TYPE statement (PR #74286)

via flang-commits flang-commits at lists.llvm.org
Wed Jan 3 05:45:51 PST 2024


================
@@ -258,6 +258,10 @@ void SelectTypeChecker::Enter(const parser::SelectTypeConstruct &construct) {
     if (IsProcedure(*selector)) {
       context_.Say(
           selectTypeStmt.source, "Selector may not be a procedure"_err_en_US);
+    } else if (evaluate::IsAssumedRank(*selector)) {
+      context_.Say(selectTypeStmt.source,
+          "Assumed-rank variable "
----------------
NimishMishra wrote:

Thanks for the review! 

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


More information about the flang-commits mailing list