This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [C++ PATCH] Fix -Wlogical-not-parentheses (PR c++/62199)
- From: Marc Glisse <marc dot glisse at inria dot fr>
- To: Jason Merrill <jason at redhat dot com>
- Cc: Marek Polacek <polacek at redhat dot com>, Paolo Carlini <paolo dot carlini at oracle dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 22 Aug 2014 21:48:31 +0200 (CEST)
- Subject: Re: [C++ PATCH] Fix -Wlogical-not-parentheses (PR c++/62199)
- Authentication-results: sourceware.org; auth=none
- References: <20140820200252 dot GO14320 at redhat dot com> <53F50CE0 dot 5010305 at redhat dot com> <20140821154125 dot GS14320 at redhat dot com> <53F63BCE dot 4050006 at redhat dot com> <20140822144848 dot GB15033 at redhat dot com> <53F75981 dot 3020401 at oracle dot com> <20140822155914 dot GD15033 at redhat dot com> <53F76EB0 dot 7000507 at redhat dot com> <20140822163357 dot GE15033 at redhat dot com> <53F77563 dot 30301 at redhat dot com> <20140822184532 dot GF15033 at redhat dot com> <alpine dot DEB dot 2 dot 11 dot 1408222117270 dot 1586 at laptop-mg dot saclay dot inria dot fr> <53F79AB4 dot 6030307 at redhat dot com>
On Fri, 22 Aug 2014, Jason Merrill wrote:
On 08/22/2014 03:24 PM, Marc Glisse wrote:
Note that there is a patch waiting for a review that makes us accept !v
for vector v:
Ah, indeed. I still think we might as well treat vectors the same as other
types here.
Ok, now that it is a conscious choice, it feels much safer :-)
Though depending on where exactly this is called, it would be funny if we
warned for !v==-1 but not for !v==true, when the possible values for the
elements of !v are actually {-1,0}. I guess I'll have to test after Marek
commits.
Thanks,
--
Marc Glisse