Re: Patch for isdigit/isalpha/etc. macro arguments

Steve Ellcey
2007-04-10T21:16:22Z

Well, this discussion was very interesting but I am not sure it led
anywhere. If casting to '(int)' is unacceptable, double casting to
'(int) (unsigned char)' is probably even less acceptable so I would like
to check in the following patch that turns off the warnings so I can
build on HPPA HP-UX.

Tested by building on HPPA HP-UX.

OK to checkin?

2007-04-10 Steve Ellcey <sje@cup.hp.com>

* configure.ac (build_warnings): Add -Wno-char-subscripts.
* doc/gdbint.texinfo (warning flags): Add -Wno-char-subscripts.

Index: configure.ac
===================================================================
RCS file: /cvs/src/src/gdb/configure.ac,v
retrieving revision 1.43
diff -u -p -r1.43 configure.ac
--- configure.ac 29 Mar 2007 15:24:28 -0000 1.43
+++ configure.ac 10 Apr 2007 21:08:01 -0000
@@ -1169,7 +1169,7 @@ fi
# gdb/doc/gdbint.texinfo.
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
-Wformat-nonliteral -Wno-pointer-sign \
--Wno-unused -Wno-switch"
+-Wno-unused -Wno-switch -Wno-char-subscripts"

AC_ARG_ENABLE(build-warnings,
[ --enable-build-warnings Enable build-time compiler warnings if gcc is used],
Index: doc/gdbint.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdbint.texinfo,v
retrieving revision 1.258
diff -u -p -r1.258 gdbint.texinfo
--- doc/gdbint.texinfo 10 Apr 2007 11:58:15 -0000 1.258
+++ doc/gdbint.texinfo 10 Apr 2007 21:08:03 -0000
@@ -5638,6 +5638,7 @@ is being used.

@item -Wno-unused
@itemx -Wno-switch
+@itemx -Wno-char-subscripts
These are warnings which might be useful for @value{GDBN}, but are
currently too noisy to enable with @samp{-Werror}.