From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26900 invoked by alias); 19 Aug 2008 16:59:16 -0000 Received: (qmail 26889 invoked by uid 22791); 19 Aug 2008 16:59:15 -0000 X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 19 Aug 2008 16:57:50 +0000 Received: from wpaz9.hot.corp.google.com (wpaz9.hot.corp.google.com [172.24.198.73]) by smtp-out3.google.com with ESMTP id m7JGvWla024522; Tue, 19 Aug 2008 17:57:32 +0100 Received: from localhost.localdomain.google.com (dhcp-172-18-118-203.corp.google.com [172.18.118.203]) (authenticated bits=0) by wpaz9.hot.corp.google.com with ESMTP id m7JGvTd2028031 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Tue, 19 Aug 2008 09:57:31 -0700 To: Richard Harvey Chapman Cc: gcc Subject: Re: regarding type promotion References: <48AA5377.9080001@redpinesignals.com> <1219162574.6008.7.camel@bob-desktop> <48AAF5B6.3030704@3gfp.com> From: Ian Lance Taylor Date: Tue, 19 Aug 2008 17:02:00 -0000 In-Reply-To: <48AAF5B6.3030704@3gfp.com> (Richard Harvey Chapman's message of "Tue\, 19 Aug 2008 12\:32\:54 -0400") Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-08/txt/msg00178.txt.bz2 Richard Harvey Chapman writes: > Bob Plantz wrote: >> Another rule I gave them is "multiplication and division have higher >> precedence than addition and subtraction; use parentheses in all other >> cases." > ++ > > I used to always get tripped up in embedded code because "==" has > precedence over "&" which I do not believe is intuitive to most > people. That's why gcc warns about it, with -Wparentheses, which is part of -Wall. Ian