view gcc/testsuite/gfortran.dg/elemental_pointer_1.f90 @ 158:494b0b89df80 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 25 May 2020 18:13:55 +0900
parents 04ced10e8804
children
line wrap: on
line source

! { dg-do compile }
! Tests the fix for pr20875.
! Note 12.7.1 "For a function, the result shall be scalar and shall not have the POINTER attribute."
MODULE Test
CONTAINS
  ELEMENTAL FUNCTION LL(I)
    INTEGER, INTENT(IN) :: I
    INTEGER :: LL
    POINTER  :: LL ! { dg-error " POINTER attribute conflicts with ELEMENTAL attribute" }
  END FUNCTION LL
END MODULE Test