From owner-freebsd-toolchain@FreeBSD.ORG Thu Nov 3 11:01:55 2011 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 0C9A51065675; Thu, 3 Nov 2011 11:01:55 +0000 (UTC) Date: Thu, 3 Nov 2011 11:01:55 +0000 From: Alexander Best To: Gerald Pfeifer , Matthias Andree , Warner Losh , Roman Divacky Message-ID: <20111103110155.GA32672@freebsd.org> References: <20111017152548.GA66978@freebsd.org> <12466AAB-625F-4D20-80E6-2D4235ED81EC@bsdimp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <12466AAB-625F-4D20-80E6-2D4235ED81EC@bsdimp.com> Cc: freebsd-toolchain@freebsd.org Subject: Re: [toolchain] disable -Wtautological-compare for clang X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 Nov 2011 11:01:55 -0000 On Mon Oct 17 11, Warner Losh wrote: > I'm all for leaving it on because things like char are signed on some architectures and unsigned on others. This leads to bugs that only appear on one architecture. This warning will, at least, flag those usages. -funsigned-char / -fsigned-char could be used in that case. cheers. alex > > On Oct 17, 2011, at 10:56 AM, Gerald Pfeifer wrote: > > > On Mon, 17 Oct 2011, Alexander Best wrote: > >> any chance we could disable -Wtautological-compare for clang? i don't > >> think comparing an unsigned int against < 0 is worth a warning. actually > >> it's always nice to have such a seatbelt, in case somebody changes the > >> type to int and forgets to introduce such a check. > > > > I am on the fence on this one, for when I used the equivalent warning > > in GCC this did found a number of real issues that I then addressed for > > Wine (as an example). > > > > Gerald > > _______________________________________________ > > freebsd-toolchain@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-toolchain > > To unsubscribe, send any mail to "freebsd-toolchain-unsubscribe@freebsd.org" > > > > >