PR c++/64767 * c.opt (Wpointer-compare): New option. * c-parser.c (c_parser_postfix_expression): Mark zero character constants by setting original_type in c_expr. * c-typeck.c (parser_build_binary_op): Warn when a pointer is compared with a zero character constant. (char_type_p): New function. * typeck.c (cp_build_binary_op): Warn when a pointer is compared with a zero character literal. * doc/invoke.texi: Document -Wpointer-compare. * c-c++-common/Wpointer-compare-1.c: New test. From-SVN: r244076
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
ChangeLog | Loading commit data... | |
Make-lang.in | Loading commit data... | |
c-array-notation.c | Loading commit data... | |
c-aux-info.c | Loading commit data... | |
c-convert.c | Loading commit data... | |
c-decl.c | Loading commit data... | |
c-errors.c | Loading commit data... | |
c-fold.c | Loading commit data... | |
c-lang.c | Loading commit data... | |
c-lang.h | Loading commit data... | |
c-objc-common.c | Loading commit data... | |
c-objc-common.h | Loading commit data... | |
c-parser.c | Loading commit data... | |
c-parser.h | Loading commit data... | |
c-tree.h | Loading commit data... | |
c-typeck.c | Loading commit data... | |
config-lang.in | Loading commit data... | |
gccspec.c | Loading commit data... | |
gimple-parser.c | Loading commit data... | |
gimple-parser.h | Loading commit data... |