From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20535 invoked by alias); 19 Feb 2007 19:14:49 -0000 Received: (qmail 20436 invoked by uid 48); 19 Feb 2007 19:14:38 -0000 Date: Mon, 19 Feb 2007 19:14:00 -0000 Message-ID: <20070219191438.20435.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c++/30860] Should warn about boolean constant false used in pointer context In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "manu at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2007-02/txt/msg02219.txt.bz2 ------- Comment #3 from manu at gcc dot gnu dot org 2007-02-19 19:14 ------- (In reply to comment #1) > manu, is this something already covered by your pending -Wconversion fixes? > No, it is not. And I don't think it should be warned by -Wconversion. After all, no value is changed during the conversion. On the other hand, we give an error for: void foo(const char *); void bar() { foo(1 != 0); } error: cannot convert ‘bool’ to ‘const char*’ for argument ‘1’ to ‘void foo(const char*)’ -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30860