r260973 - in /trunk/gcc: cp/ChangeLog cp/call.c...

ville@gcc.gnu.org ville@gcc.gnu.org
Wed May 30 19:33:00 GMT 2018


Author: ville
Date: Wed May 30 19:33:38 2018
New Revision: 260973

URL: https://gcc.gnu.org/viewcvs?rev=260973&root=gcc&view=rev
Log:
Do not warn about zero-as-null when NULL is used.

gcc/cp/

Do not warn about zero-as-null when NULL is used.
* call.c (conversion_null_warnings): Check for pointer
types converted from zero constants.
(convert_like_real): Add a warning sentinel at the end.
* tree.c (maybe_warn_zero_as_null_pointer_constant): Also
check null_node_p.

testsuite/

Do not warn about zero-as-null when NULL is used.
* g++.dg/warn/Wzero-as-null-pointer-constant-7.C: New.

Added:
    trunk/gcc/testsuite/g++.dg/warn/Wzero-as-null-pointer-constant-7.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/call.c
    trunk/gcc/cp/tree.c



More information about the Gcc-cvs mailing list