1 ! REQUIRES: openmp_runtime
3 ! RUN: %python %S/../test_errors.py %s %flang_fc1 %openmp_flags
5 ! 2.11.3 allocate Directive
6 ! The allocate directive must appear in the same scope as the declarations of
7 ! each of its list items and must follow all such declarations.
11 integer, allocatable
:: x(:)
16 real, dimension (:,:), allocatable
:: darray
18 !ERROR: List items must be declared in the same scoping unit in which the ALLOCATE directive appears
22 !ERROR: List items must be declared in the same scoping unit in which the ALLOCATE directive appears
23 !$omp allocate(x) allocator(omp_default_mem_alloc)
24 allocate ( x(a
), darray(a
, b
) )
27 end subroutine allocate