diff options
author | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2016-03-13 00:19:08 +0000 |
---|---|---|
committer | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2016-03-13 00:19:08 +0000 |
commit | a4c54bf2a79469093e8742ec3e22ae09f14da4b5 (patch) | |
tree | e5ca4eadbe1abca4cd1c4047876467c45f49dd7a /gcc/fortran/options.c | |
parent | 4d4d5abe2eeb3a978027fdbb45e356a120da4ae2 (diff) | |
download | gcc-a4c54bf2a79469093e8742ec3e22ae09f14da4b5.zip gcc-a4c54bf2a79469093e8742ec3e22ae09f14da4b5.tar.gz gcc-a4c54bf2a79469093e8742ec3e22ae09f14da4b5.tar.bz2 |
re PR fortran/69520 (Implement reversal of -fcheck options)
2016-03-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
Harold Anlauf <anlauf@gmx.de>
PR fortran/69520
* invoke.texi: Explain use of the 'no-' construct within the
-fcheck= option.
* options.c (gfc_handle_runtime_check_option): Enable use of
'no-' prefix for the various options with -fcheck= to allow
negating previously enabled check options.
Co-Authored-By: Harald Anlauf <anlauf@gmx.de>
From-SVN: r234167
Diffstat (limited to 'gcc/fortran/options.c')
-rw-r--r-- | gcc/fortran/options.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/fortran/options.c b/gcc/fortran/options.c index f8d8f8d..0fcda1d 100644 --- a/gcc/fortran/options.c +++ b/gcc/fortran/options.c @@ -515,6 +515,15 @@ gfc_handle_runtime_check_option (const char *arg) result = 1; break; } + else if (optname[n] && pos > 3 && strncmp ("no-", arg, 3) == 0 + && strncmp (optname[n], arg+3, pos-3) == 0) + { + gfc_option.rtcheck &= ~optmask[n]; + arg += pos; + pos = 0; + result = 1; + break; + } } if (!result) gfc_fatal_error ("Argument to %<-fcheck%> is not valid: %s", arg); |