Files
clang-p2996/flang/test/Semantics/call35.f90
Andre Kuhlenschmidt 83b462af17 [flang][CLI] Have the CLI hint the flag to disable a warning (#144767)
Adds a hint to the warning message to disable a warning and updates the
tests to expect this.

Also fixes a bug in the storage of canonical spelling of error flags so
that they are not used after free.
2025-06-30 10:17:05 -07:00

24 lines
793 B
Fortran

! RUN: %python %S/test_errors.py %s %flang_fc1 -Werror
subroutine s1
call ext(1, 2)
call myerror('abc')
end
subroutine s2
!WARNING: Reference to the procedure 'ext' has an implicit interface that is distinct from another reference: distinct numbers of dummy arguments [-Wincompatible-implicit-interfaces]
call ext(1.)
call myerror('abcd') ! don't warn about distinct lengths
end
subroutine s3
interface
!WARNING: The global subprogram 'ext' is not compatible with its local procedure declaration (incompatible procedure attributes: ImplicitInterface) [-Wexternal-interface-mismatch]
subroutine ext(n)
integer n
end
end interface
call ext(3)
!ERROR: Actual argument type 'REAL(4)' is not compatible with dummy argument type 'INTEGER(4)'
call ext(4.)
end