This is the mail archive of the
mailing list for the GDB project.
Re: [PATCH OBV] Add nowarnings in gdb.base/fileio.exp
Pedro Alves <email@example.com> writes:
> I don't think so. I think that'd be the equivalent of saying that we
> don't support debugging target code built with gcc versions earlier
> than 4.6. That's a totally different discussion from the discussion
> about requirements for building gdb.
That is what I meant by "require gcc 4.6 to run testsuite". If we use
such diagnostic in tests, we need gcc 4.6 or later to compile gdb test
> How about an even simpler fix: pass a global pointer variable that
> happens to be NULL to stat, instead of a NULL literal. The compiler can't
> prove (without LTO) that the variable may still be NULL, so it doesn't
> warn. Works on all compilers I tried it on: gcc 3.4/5.3/7, clang 3.7.
> Let me send a mini series in reply to this email, which does that,
> and also fixes a few other warnings that compiling the fileio.c with
> -Wall exposes.
These three patches are good to me.