This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] PR 17946: warning message for suspect "a && MASK"
- From: "Joseph S. Myers" <jsm at polyomino dot org dot uk>
- To: "Thomas R. Truscott" <trt at cs dot duke dot edu>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Tue, 12 Oct 2004 17:11:04 +0000 (UTC)
- Subject: Re: [PATCH] PR 17946: warning message for suspect "a && MASK"
- References: <200410121421.i9CELxGb021561@eenie.cs.duke.edu>
On Tue, 12 Oct 2004, Thomas R. Truscott wrote:
> There is an ugly aspect to the patch.
> c-parse.in converts A to truth value (A != 0) to update "skip_evaluation".
> But the unconverted A is needed for this warning check.
> To get around this, the patch does a temporary conversion. Twice. Yuck.
I think this may lead to duplicate diagnostics from truthvalue_conversion
if the expression being used as a truth value isn't valid as such.
--
Joseph S. Myers http://www.srcf.ucam.org/~jsm28/gcc/
jsm@polyomino.org.uk (personal mail)
joseph@codesourcery.com (CodeSourcery mail)
jsm28@gcc.gnu.org (Bugzilla assignments and CCs)