diff options
Diffstat (limited to 'flang/lib/Semantics/pointer-assignment.cpp')
-rw-r--r-- | flang/lib/Semantics/pointer-assignment.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/flang/lib/Semantics/pointer-assignment.cpp b/flang/lib/Semantics/pointer-assignment.cpp index dc5611c..8cf46f5 100644 --- a/flang/lib/Semantics/pointer-assignment.cpp +++ b/flang/lib/Semantics/pointer-assignment.cpp @@ -169,7 +169,9 @@ bool PointerAssignmentChecker::Check(const evaluate::FunctionRef<T> &f) { } else if (lhsType_) { const auto *frTypeAndShape{funcResult->GetTypeAndShape()}; CHECK(frTypeAndShape); - if (!lhsType_->IsCompatibleWith(context_.messages(), *frTypeAndShape)) { + if (!lhsType_->IsCompatibleWith(context_.messages(), *frTypeAndShape, + "pointer", "function result", false /*elemental*/, + true /*left: deferred shape*/, true /*right: deferred shape*/)) { msg = "%s is associated with the result of a reference to function '%s'" " whose pointer result has an incompatible type or shape"_err_en_US; } |