From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by listman.redhat.com (Postfix) with ESMTP id C9B53403E7 for ; Fri, 8 Nov 2002 12:28:27 -0500 (EST) Received: (from mail@localhost) by int-mx1.corp.redhat.com (8.11.6/8.11.6) id gA8HSRg24104 for axp-list@listman.redhat.com; Fri, 8 Nov 2002 12:28:27 -0500 Received: from mx1.redhat.com (mx1.redhat.com [172.16.48.31]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with SMTP id gA8HSRf24100 for ; Fri, 8 Nov 2002 12:28:27 -0500 Received: from ellpspace.math.ualberta.ca (ellpspace.math.ualberta.ca [129.128.207.67]) by mx1.redhat.com (8.11.6/8.11.6) with SMTP id gA8H5dw00627 for ; Fri, 8 Nov 2002 12:05:39 -0500 Received: (from michal@localhost) by ellpspace.math.ualberta.ca (8.11.6/8.11.6) id gA8HSNG04541 for axp-list@redhat.com; Fri, 8 Nov 2002 10:28:23 -0700 Date: Fri, 8 Nov 2002 10:28:23 -0700 From: Michal Jaegermann To: axp-list@redhat.com Subject: Re: [PATCH] eliminate compile warnings Message-ID: <20021108102823.A4439@ellpspace.math.ualberta.ca> References: <20021106214705.A15525@Marvin.DL8BCU.ampr.org> <02110709222600.14483@shadowfax.middleearth> <20021107202855.B17028@Marvin.DL8BCU.ampr.org> <20021107173349.A4017@twiddle.net> <20021108073845.A17905@Marvin.DL8BCU.ampr.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20021108073845.A17905@Marvin.DL8BCU.ampr.org>; from dl8bcu@dl8bcu.de on Fri, Nov 08, 2002 at 07:38:45AM +0000 X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0.1 Precedence: bulk Reply-To: axp-list@redhat.com List-Help: List-Post: List-Subscribe: , List-Id: Linux and Red Hat on Alpha processors List-Unsubscribe: , List-Archive: On Fri, Nov 08, 2002 at 07:38:45AM +0000, Thorsten Kranzkowski wrote: > > I will give my patch another thought and I will feed it to you in smaller > pieces and with comments. You will have much better chances for correctness and acceptance if you will try to _reduce_ number of casts by making sure that types of objects agree, if only possible, instead of sprinkling code with extra casts. Every such thing is a potential spot for a masked bug although side effects of a missed signed/unsigned comparison can also be nasty. But if you want a unsigned constant with all bits on then ~0UL is surely preferable over casting (-1) to unsigned long; even if just for clarity. BTW - contrary to claim by Richard I found something like 45 lines changed in that patch insted of "hundreds". :-) No, I am not trying to convince anybody that this number is small enough. Michal