brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · d8209a6 Raw
39 lines · plain
1! RUN: %python %S/test_errors.py %s %flang_fc12 3module m4  type t15    integer, allocatable :: a(:)6  end type7  type t28    integer :: n = 1239  end type10  type t311   contains12    final :: t3final13  end type14  type t415    type(t1) :: c116    type(t2) :: c217    type(t3) :: c318  end type19  type t520  end type21 contains22  elemental subroutine t3final(x)23    type(t3), intent(in) :: x24  end subroutine25  subroutine test1(x1,x2,x3,x4,x5)26    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not have a derived type with any default component initialization27    type(t1), intent(out) :: x1(*)28    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not have a derived type with any default component initialization29    type(t2), intent(out) :: x2(*)30    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not be finalizable31    type(t3), intent(out) :: x3(*)32    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not have a derived type with any default component initialization33    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not be finalizable34    type(t4), intent(out) :: x4(*)35    !ERROR: An INTENT(OUT) assumed-size dummy argument array may not be polymorphic36    class(t5), intent(out) :: x5(*)37  end subroutine38end module39