diff options
author | Ben Elliston <bje@au.ibm.com> | 2005-12-13 23:33:26 +0000 |
---|---|---|
committer | Ben Elliston <bje@gcc.gnu.org> | 2005-12-14 10:33:26 +1100 |
commit | 690a704a4e5eda3745d4b0d650cba90a36702a64 (patch) | |
tree | d72ae86b6320671af20df2fd5c12deb106455c3a /gcc/loop-unswitch.c | |
parent | 383eca9ccea8275baab7d6bdf5f464e113482dec (diff) | |
download | gcc-690a704a4e5eda3745d4b0d650cba90a36702a64.zip gcc-690a704a4e5eda3745d4b0d650cba90a36702a64.tar.gz gcc-690a704a4e5eda3745d4b0d650cba90a36702a64.tar.bz2 |
c-common.c (c_common_truthvalue_conversion): Generalise warning for addresses converted to booleans; not just function addresses.
* c-common.c (c_common_truthvalue_conversion): Generalise warning
for addresses converted to booleans; not just function addresses.
* c-typeck.c (build_binary_op): Warn for address comparisons which
can never be NULL (eg. func == NULL or &var == NULL).
* common.opt (Walways-true): New option.
* c-opts.c (c_common_handle_option): Set it with -Wall.
* doc/invoke.texi: Document it.
testsuite/
* gcc.dg/warn-addr-cmp.c: New test.
From-SVN: r108489
Diffstat (limited to 'gcc/loop-unswitch.c')
0 files changed, 0 insertions, 0 deletions