[PATCH OBV] Add nowarnings in gdb.base/fileio.exp

Yao Qi qiyaoltc@gmail.com
Thu May 18 08:34:00 GMT 2017


Pedro Alves <palves@redhat.com> writes:

> FWIW, I think that wrapping the offending code with
>
>  #pragma diagnostics push
>  #pragma diagnostics ignored "-Wnonnull"
>  ... stat (NULL, ...);
>  #pragma diagnostics pop
>
> would be appropriate in this case.  This testcase is checking that the syscalls
> on the target map back to host I/O on the gdb side, and some targets have
> slightly non-POSIX-like system calls APIs; IMHO, it's better to see warnings
> due to such mismatches instead of potentially silently miscompiling.

The diagnostic was added in gcc 4.6.  Do we require gcc 4.6 to run
testsuite?  I am OK with this requirement.

-- 
Yao (齐尧)



More information about the Gdb-patches mailing list