Message ID | AM4PR0701MB2162C05959D824E57DDC6B12E4FF0@AM4PR0701MB2162.eurprd07.prod.outlook.com |
---|---|
State | New |
Headers | show
Return-Path: <gcc-patches-return-435710-incoming=patchwork.ozlabs.org@gcc.gnu.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3sY0sg5CKJz9sdm for <incoming@patchwork.ozlabs.org>; Tue, 13 Sep 2016 07:13:42 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=qOuAGmIJ; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:references:in-reply-to:content-type :content-id:content-transfer-encoding:mime-version; q=dns; s= default; b=hd6aUbLZ94J3QCVZvvzWDYuxu+qSOj+QVr0ZRJ7ESEMFYFiEpiry3 b4qHLUeGP2mtYXI94aXEObM4otc28KHS9uPI5/y7qTqYaRoMT+RtqosNLWCx6NhF IcsSflk8etV+QeaS5EX6oipoXeX8CCFyk+r2n65axqcBcTVc/afOPI= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:references:in-reply-to:content-type :content-id:content-transfer-encoding:mime-version; s=default; bh=Bjy0WWrMJ3KePJzNyPawZcHWQBQ=; b=qOuAGmIJkS7UmnXLppfd7MHuCA7i T19n146+pN2jqwa435M14A5oun7AqHQ7HPDT+yoA55WWbIK6WdiaVQH70+L2v5mC WvXDhOPA8DFFlR7lzXTu5BQkVUdnT1O8vXtkdu+T5+MaBnTeFyA4wqsDT0K5Es5t +wCLAqphBh5h0Mw= Received: (qmail 34735 invoked by alias); 12 Sep 2016 21:13:32 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: <gcc-patches.gcc.gnu.org> List-Unsubscribe: <mailto:gcc-patches-unsubscribe-incoming=patchwork.ozlabs.org@gcc.gnu.org> List-Archive: <http://gcc.gnu.org/ml/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-help@gcc.gnu.org> Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 34718 invoked by uid 89); 12 Sep 2016 21:13:31 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-spam-relays-external:sk:blu004-, HX-HELO:sk:BLU004-, H*RU:sk:blu004-, Hx-spam-relays-external:sk:BLU004- X-HELO: BLU004-OMC4S20.hotmail.com Received: from blu004-omc4s20.hotmail.com (HELO BLU004-OMC4S20.hotmail.com) (65.55.111.159) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 12 Sep 2016 21:13:21 +0000 Received: from EUR01-VE1-obe.outbound.protection.outlook.com ([65.55.111.135]) by BLU004-OMC4S20.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008); Mon, 12 Sep 2016 14:13:19 -0700 Received: from VE1EUR01FT051.eop-EUR01.prod.protection.outlook.com (10.152.2.60) by VE1EUR01HT190.eop-EUR01.prod.protection.outlook.com (10.152.3.229) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.619.6; Mon, 12 Sep 2016 21:13:12 +0000 Received: from AM4PR0701MB2162.eurprd07.prod.outlook.com (10.152.2.52) by VE1EUR01FT051.mail.protection.outlook.com (10.152.3.8) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.619.6 via Frontend Transport; Mon, 12 Sep 2016 21:13:12 +0000 Received: from AM4PR0701MB2162.eurprd07.prod.outlook.com ([10.167.132.147]) by AM4PR0701MB2162.eurprd07.prod.outlook.com ([10.167.132.147]) with mapi id 15.01.0619.011; Mon, 12 Sep 2016 21:13:12 +0000 From: Bernd Edlinger <bernd.edlinger@hotmail.de> To: Jeff Law <law@redhat.com>, "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>, Joseph Myers <joseph@codesourcery.com>, "Jason Merrill" <jason@redhat.com> Subject: Re: [PATCH] Add a warning for suspicious use of conditional expressions in boolean context Date: Mon, 12 Sep 2016 21:13:12 +0000 Message-ID: <AM4PR0701MB2162C05959D824E57DDC6B12E4FF0@AM4PR0701MB2162.eurprd07.prod.outlook.com> References: <AM4PR0701MB21624AB3DECA1269E4BBB475E4E50@AM4PR0701MB2162.eurprd07.prod.outlook.com> <4fd68972-b48b-560a-b8e2-ae7d607b9b87@redhat.com> <AM4PR0701MB216265F6259DAEEFB6C52AA0E4FF0@AM4PR0701MB2162.eurprd07.prod.outlook.com> <48602fe1-c295-fce5-a6fe-e7e259532f44@redhat.com> In-Reply-To: <48602fe1-c295-fce5-a6fe-e7e259532f44@redhat.com> authentication-results: spf=softfail (sender IP is 10.152.2.52) smtp.mailfrom=hotmail.de; redhat.com; dkim=none (message not signed) header.d=none; redhat.com; dmarc=none action=none header.from=hotmail.de; received-spf: SoftFail (protection.outlook.com: domain of transitioning hotmail.de discourages use of 10.152.2.52 as permitted sender) x-ms-exchange-messagesentrepresentingtype: 1 x-eopattributedmessage: 0 x-forefront-antispam-report: CIP:10.152.2.52; IPV:NLI; CTRY:; EFV:NLI; SFV:NSPM; SFS:(10019020)(98900003); DIR:OUT; SFP:1102; SCL:1; SRVR:VE1EUR01HT190; H:AM4PR0701MB2162.eurprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; x-microsoft-exchange-diagnostics: 1; VE1EUR01HT190; 6:+NFn0+V82TQBLk1w1wIvS5kqiwpTnpFZqo6L0LcrZi4UWUSE9uwAAexGKFk4/71dyMIS2DBbAnM9m8Pi2F6rpAMQ92fPt2CsBhMNdsPtlXIn6vWJt7O05fMUadqyknmZk38DcOqxRTKpsTgbxn6f4Y/ZqwYFhLnZWRPIIjZ2oEWwXkHvy+FGFTHWOlP5dwOQ/WgmACO/QWVGPKCiL02RDY6nFche8Eq1TZc0j1DMcP6fqdES+4Pa2Dj/BKOyRugYbtUiX2NP2JfPMGU/L7AfTZ0+g612io6j+KGSbIIgcr03U0EXlSJ+URIYo/h2YhS4; 5:ACWBITaRD/P0o8BoJW0NmFxfL+tojpRtUs4nkJQxAO+z/xhHHUlxNJ/AVrGszxKBVQQKO0gJytdVLHhr2xVta1H7sZ/4A1w0AXvrSTDeKaQZaKAAjxfL4h+PDgSZVSenrlHTQhi5bIOVBI+afLD1Ew==; 24:Ul2JXSZqMiz8uanAPG8Nweky7lZRXN96XydpRtagymKrQ0bhtjCB+IdtcR9C+XUQC0z+stdTEXHQu5vWjvBdN8DGzgH/eCLYmk4cpKT/x9s=; 7:Q7lBFTrXEy3r7Eq7ZUtgzr1UFDEP0BS1prx4CCCLme4iShybpofnPwOcmmo82QFOCN83+Ia38qqvaH3ffP7B8QmJOXaRKqQASQt1jaF8U8i0HGoQnlsk97oQPZiL6ICscqc0q00wM9j28rQlgYaUwCi6uL71aAqFWBHBYAlhlh5CKmH+p3SLE5jsysd4wxdwcqanDy68tDxwmOmy2N6+mJe06jNli2jQ4GR0CWAmbnja04xCA6NPr57If1+LkAb7 x-ms-office365-filtering-correlation-id: e3232097-c686-4fa7-92aa-08d3db5199ec x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(1601124038)(1603103081)(1601125047); SRVR:VE1EUR01HT190; x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(432015012)(82015046); SRVR:VE1EUR01HT190; BCL:0; PCL:0; RULEID:; SRVR:VE1EUR01HT190; x-forefront-prvs: 006339698F spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="Windows-1252" Content-ID: <081FD242D8A9C64691F890AA5EDC6895@eurprd07.prod.outlook.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Sep 2016 21:13:12.3384 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1EUR01HT190 |
Index: gensupport.c =================================================================== --- gensupport.c (revision 240097) +++ gensupport.c (working copy) @@ -201,15 +201,15 @@ #define TRISTATE_AND(a,b) \ ((a) == I ? ((b) == N ? N : I) : \ (b) == I ? ((a) == N ? N : I) : \ - (a) && (b)) + (a) == Y && (b) == Y ? Y : N) #define TRISTATE_OR(a,b) \ ((a) == I ? ((b) == Y ? Y : I) : \ (b) == I ? ((a) == Y ? Y : I) : \ - (a) || (b)) + (a) == Y || (b) == Y ? Y : N) #define TRISTATE_NOT(a) \ - ((a) == I ? I : !(a)) + ((a) == I ? I : (a) == Y ? N : Y) /* 0 means no warning about that code yet, 1 means warned. */ static char did_you_mean_codes[NUM_RTX_CODE];