[all-commits] [llvm/llvm-project] 9f7aac: [flang] Allow host-associated INTENT(OUT) in speci...
Peter Klausler via All-commits
all-commits at lists.llvm.org
Mon Apr 14 09:00:40 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9f7aac177cac18e03ca68e2a69e06700250cd3d7
https://github.com/llvm/llvm-project/commit/9f7aac177cac18e03ca68e2a69e06700250cd3d7
Author: Peter Klausler <pklausler at nvidia.com>
Date: 2025-04-14 (Mon, 14 Apr 2025)
Changed paths:
M flang/docs/Extensions.md
M flang/include/flang/Support/Fortran-features.h
M flang/lib/Evaluate/check-expression.cpp
M flang/lib/Support/Fortran-features.cpp
M flang/test/Semantics/spec-expr.f90
Log Message:
-----------
[flang] Allow host-associated INTENT(OUT) in specification expr. (#135426)
Nearly, but not all, other compilers have a blanket prohibition against
the use of an INTENT(OUT) dummy argument in a specification expression.
Some compilers, however, permit an INTENT(OUT) dummy argument to appear
in a specification expression in a BLOCK construct or inner procedure
via host association.
The argument some have put forth to accept this usage comes from a
reading of 10.1.11 (specification expressions) in Fortran 2023 that, if
followed consistently, would also require host-associated OPTIONAL dummy
argument to be allowed. That would be dangerous for reasons that should
be obvious.
However, I can agree that a non-OPTIONAL dummy argument can't be assumed
to remain undefined on entry to a BLOCK construct or inner procedure, so
we can accept host-associated INTENT(OUT) in specification expressions
with a portability warning.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list