gcc/testsuite/gfortran.dg/pr107899.f90
raw| 1 | ! { dg-do compile } |
| 2 | ! { dg-options "-fcoarray=single" } |
| 3 | ! PR fortran/107899 - ICE in resolve_deallocate_expr |
| 4 | ! Contributed by G.Steinmetz |
| 5 | |
| 6 | program p |
| 7 | type t |
| 8 | end type |
| 9 | class(t), target :: x[:] ! { dg-error "deferred shape" } |
| 10 | if (allocated (x)) then ! { dg-error "must be ALLOCATABLE" } |
| 11 | deallocate (x) ! { dg-error "must be ALLOCATABLE or a POINTER" } |
| 12 | end if |
| 13 | end |