Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gfortran.dg/associate_7.f03 @ 127:4c56639505ff
fix function.c and add CbC-example Makefile
author | mir3636 |
---|---|
date | Wed, 11 Apr 2018 18:46:58 +0900 |
parents | 04ced10e8804 |
children | 84e7813d76e9 |
line wrap: on
line source
! { dg-do run } ! { dg-options "-std=f2003 -fall-intrinsics" } ! PR fortran/38936 ! Check association and pointers. ! Contributed by Daniel Kraft, d@domob.eu. PROGRAM main IMPLICIT NONE INTEGER, TARGET :: tgt INTEGER, POINTER :: ptr tgt = 1 ASSOCIATE (x => tgt) ptr => x IF (ptr /= 1) CALL abort () ptr = 2 END ASSOCIATE IF (tgt /= 2) CALL abort () END PROGRAM main