diff options
author | Tom Tromey <tromey@adacore.com> | 2019-12-05 08:36:31 -0700 |
---|---|---|
committer | Tom Tromey <tromey@adacore.com> | 2019-12-13 15:15:32 -0700 |
commit | 634561834ea3a089d6d535c56b923c7869c8a7c9 (patch) | |
tree | 549672fafa422ab55add5cad76383f7652349d3d /gdb | |
parent | 98f9338a584c5f68595fc97e692e83f700c8da3d (diff) | |
download | gdb-634561834ea3a089d6d535c56b923c7869c8a7c9.zip gdb-634561834ea3a089d6d535c56b923c7869c8a7c9.tar.gz gdb-634561834ea3a089d6d535c56b923c7869c8a7c9.tar.bz2 |
Accept -Wno- prefix in ARI
This adds -Wno- support to ARI, so that warnings can be disabled
selectively. I use this to ignore "deprecated" warnings.
gdb/ChangeLog
2019-12-13 Tom Tromey <tromey@adacore.com>
* contrib/ari/gdb_ari.sh: Handle -Wno- prefix.
Change-Id: I6919faedf920e857df4f597df66f0ba3943e0eac
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 4 | ||||
-rwxr-xr-x | gdb/contrib/ari/gdb_ari.sh | 19 |
2 files changed, 20 insertions, 3 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 93b0762..d30611f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,9 @@ 2019-12-13 Tom Tromey <tromey@adacore.com> + * contrib/ari/gdb_ari.sh: Handle -Wno- prefix. + +2019-12-13 Tom Tromey <tromey@adacore.com> + * contrib/ari/gdb_ari.sh (usage): Use GNU style. 2019-12-13 Tom Tromey <tromey@adacore.com> diff --git a/gdb/contrib/ari/gdb_ari.sh b/gdb/contrib/ari/gdb_ari.sh index 4b0fddf..02c3647 100755 --- a/gdb/contrib/ari/gdb_ari.sh +++ b/gdb/contrib/ari/gdb_ari.sh @@ -60,7 +60,8 @@ Options: -Werror Treat all problems as errors. -Wall Report all problems. -Wari Report problems that should be fixed in new code. - -WCATEGORY Report problems in the specifed category. Valid categories + -WCATEGORY Report problems in the specifed category. The category + can be prefixed with "no-". Valid categories are: ${all} EOF exit 1 @@ -102,6 +103,10 @@ fi # Validate all errors and warnings. for w in ${warning} ${error} do + case "$w" in + no-*) w=`echo x$w | sed -e 's/xno-//'`;; + esac + case " ${all} " in *" ${w} "* ) ;; * ) usage "Unknown option -W${w}" ;; @@ -123,11 +128,19 @@ do done for w in ${warning} do - warnings="${warnings} warning[ari_${w}] = 1;" + val=1 + case "$w" in + no-*) w=`echo x$w | sed -e 's/xno-//'`; val=0 ;; + esac + warnings="${warnings} warning[ari_${w}] = $val;" done for e in ${error} do - errors="${errors} error[ari_${e}] = 1;" + val=1 + case "$e" in + no-*) e=`echo x$e | sed -e 's/xno-//'`; val=0 ;; + esac + errors="${errors} error[ari_${e}] = $val;" done if [ "$AWK" = "" ] ; then |