2018-09-30 Paul Thomas <pault@gcc.gnu.org>
[official-gcc.git] / gcc / testsuite / gfortran.dg / c_by_val_4.f
blobc8f4b0484dd7e1600611ed47a2054c0c52600f69
1 C { dg-do compile }
2 C Tests the fix for PR30888, in which the dummy procedure would
3 C generate an error with the %VAL argument, even though it is
4 C declared EXTERNAL.
6 C Contributed by Peter W. Draper <p.w.draper@durham.ac.uk>
8 SUBROUTINE VALTEST( DOIT )
9 EXTERNAL DOIT
10 INTEGER P
11 INTEGER I
12 I = 0
13 P = 0
14 CALL DOIT( %VAL( P ) ) ! { dg-warning "Extension: argument list function" }
15 CALL DOIT( I )
16 CALL DOIT( %VAL( P ) ) ! { dg-warning "Extension: argument list function" }
17 END