diff options
author | Jakub Jelinek <jakub@redhat.com> | 2017-01-06 19:41:23 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2017-01-06 19:41:23 +0100 |
commit | 75213cc0e4b3afd8e677f25e4fe9201f1b856f33 (patch) | |
tree | ebd5bb77a7e172ea127be4131f30b16e786f21f5 /gcc/fortran/simplify.c | |
parent | 9a38f84e274c6724172ec676285277a3003336ee (diff) | |
download | gcc-75213cc0e4b3afd8e677f25e4fe9201f1b856f33.zip gcc-75213cc0e4b3afd8e677f25e4fe9201f1b856f33.tar.gz gcc-75213cc0e4b3afd8e677f25e4fe9201f1b856f33.tar.bz2 |
system.h (GCC_DIAGNOSTIC_PUSH_IGNORED, [...]): Define.
* system.h (GCC_DIAGNOSTIC_PUSH_IGNORED, GCC_DIAGNOSTIC_POP,
GCC_DIAGNOSTIC_STRINGIFY): Define.
* simplify.c (simplify_transformation_to_array): Use
GCC_DIAGNOSTIC_PUSH_IGNORED and GCC_DIAGNOSTIC_POP instead of
#pragma GCC diagnostic {push,ignored,pop}.
From-SVN: r244179
Diffstat (limited to 'gcc/fortran/simplify.c')
-rw-r--r-- | gcc/fortran/simplify.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/gcc/fortran/simplify.c b/gcc/fortran/simplify.c index c5e7b67..942b401 100644 --- a/gcc/fortran/simplify.c +++ b/gcc/fortran/simplify.c @@ -610,18 +610,17 @@ simplify_transformation_to_array (gfc_expr *result, gfc_expr *array, gfc_expr *d n++; if (n < result->rank) { -#pragma GCC diagnostic push /* If the nested loop is unrolled GFC_MAX_DIMENSIONS times, we'd warn for the last iteration, because the array index will have already been incremented to the array sizes, and we can't tell that this must make the test against result->rank false, because ranks must not exceed GFC_MAX_DIMENSIONS. */ -#pragma GCC diagnostic ignored "-Warray-bounds" + GCC_DIAGNOSTIC_PUSH_IGNORED (-Warray-bounds) count[n]++; base += sstride[n]; dest += dstride[n]; -#pragma GCC diagnostic pop + GCC_DIAGNOSTIC_POP } else done = true; |