From: Cesar Philippidis Date: Wed, 13 Jun 2018 14:29:04 +0000 (-0700) Subject: re PR fortran/85702 ([openacc] ICE in gfc_format_decoder, at fortran/error.c:943) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=adc41ebeab0c027cce9e1fb1e1356a66d89aeb57;p=gcc.git re PR fortran/85702 ([openacc] ICE in gfc_format_decoder, at fortran/error.c:943) PR fortran/85702 gcc/fortran/ * openmp.c (gfc_match_oacc_wait): Use %C to report error location. gcc/testsuite/ * gfortran.dg/goacc/pr85702.f90: New test. From-SVN: r261550 --- diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 9768959374d..9018933e697 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2018-06-13 Cesar Philippidis + + PR fortran/85702 + * openmp.c (gfc_match_oacc_wait): Use %C to report error location. + 2018-06-12 David Malcolm PR other/69968 diff --git a/gcc/fortran/openmp.c b/gcc/fortran/openmp.c index 5c13312585a..97d6e782373 100644 --- a/gcc/fortran/openmp.c +++ b/gcc/fortran/openmp.c @@ -2177,8 +2177,7 @@ gfc_match_oacc_wait (void) { if (el->expr == NULL) { - gfc_error ("Invalid argument to !$ACC WAIT at %L", - &wait_list->expr->where); + gfc_error ("Invalid argument to !$ACC WAIT at %C"); return MATCH_ERROR; } diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 8d5d40598a4..13a18bac08b 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2018-06-13 Cesar Philippidis + + PR fortran/85702 + * gfortran.dg/goacc/pr85702.f90: New test. + 2018-06-13 Eric Botcazou * gcc.target/i386/pr86048.c: New test. diff --git a/gcc/testsuite/gfortran.dg/goacc/pr85702.f90 b/gcc/testsuite/gfortran.dg/goacc/pr85702.f90 new file mode 100644 index 00000000000..7488618f37d --- /dev/null +++ b/gcc/testsuite/gfortran.dg/goacc/pr85702.f90 @@ -0,0 +1,6 @@ +! PR fortran/85702 +! { dg-do compile } + +subroutine s + !$acc wait(*) ! { dg-error "Invalid argument to ..ACC WAIT" } +end