gcc/testsuite/gfortran.dg/argument_checking_22.f90
raw| 1 | ! { dg-do compile } |
| 2 | ! PR 91556 - check that multiple errors are emitted for type mismatch |
| 3 | ! (and that the check is also done in contained procedures). |
| 4 | |
| 5 | program main |
| 6 | real :: a |
| 7 | call foo(a) ! { dg-error "Type mismatch" } |
| 8 | contains |
| 9 | subroutine bar |
| 10 | integer :: b |
| 11 | complex :: c |
| 12 | call foo(b) ! { dg-error "Type mismatch" } |
| 13 | call foo(c) ! { dg-error "Type mismatch" } |
| 14 | end subroutine bar |
| 15 | end program main |