Files
clang-p2996/flang/test/Semantics/call41.f90
Peter Klausler 03e50c4514 [flang] Emit warning when Hollerith actual passed to CLASS(*) (#84084)
When a Hollerith actual argument is associated with an unlimited
polymorphic dummy argument, it's treated as if it were CHARACTER. Some
other compilers treat it as if it had been BOZ, so emit a portability
warning.

Resolves https://github.com/llvm/llvm-project/issues/83548.
2024-03-13 14:11:45 -07:00

13 lines
309 B
Fortran

! RUN: %python %S/test_errors.py %s %flang_fc1 -Werror
module m
contains
subroutine unlimited(x)
class(*), intent(in) :: x
end
subroutine test
!PORTABILITY: passing Hollerith to unlimited polymorphic as if it were CHARACTER
call unlimited(6HHERMAN)
call unlimited('abc') ! ok
end
end