brintos

brintos / llvm-project-archived public Read only

0
0
Text · 629 B · 8055d21 Raw
23 lines · plain
1! REQUIRES: openmp_runtime2 3! RUN: %python %S/../test_errors.py %s %flang_fc1 %openmp_flags4! OpenMP Version 5.25! 6.7 allocators construct6! A variable that is part of another variable (as an array or7! structure element) cannot appear in an allocatprs construct.8 9subroutine allocate()10use omp_lib11 12  type my_type13    integer, allocatable :: array(:)14  end type my_type15 16  type(my_type) :: my_var17 18  !ERROR: A variable that is part of another variable (as an array or structure element) cannot appear on the ALLOCATORS directive19  !$omp allocators allocate(my_var%array)20    allocate(my_var%array(10))21 22end subroutine allocate23