From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32615 invoked by alias); 10 Feb 2015 23:16:08 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 31889 invoked by uid 89); 10 Feb 2015 23:16:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 X-HELO: mail-pa0-f53.google.com Received: from mail-pa0-f53.google.com (HELO mail-pa0-f53.google.com) (209.85.220.53) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Tue, 10 Feb 2015 23:16:06 +0000 Received: by mail-pa0-f53.google.com with SMTP id lf10so28974pab.12 for ; Tue, 10 Feb 2015 15:16:05 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=lD3wsw/EzzmesVDuOvXUQgJc7i6sEOVhD+JMhD1OY2A=; b=MRSQPc6cI55iVKWzKodxJ97dgqJy2kOel33nDYSrzAUkMYKF1S9YvWg+F4Fx42ZFeN KYFFSRHAZMtEbJQj64TlSIYUmc1/NNddN5C5UcVcoYTasbIteKhah0+mJfpy4OazkLnr IPO5r9pyx/03l4JQBX4YrIhwzVwZWBlXcEKoNzASAJO0VWrZoDlG8pe3Sk38Bm/CPAQq t95xpKZLxlEwA24MFkGTvDJKVyaPMlOxJ02rKP1nJrAN3dN8QvhO33ApVYRXkDOhTOJE sywhZUulzT+Jm/o2PUJI5FWO0rPzbb5uEoD0x/+Cb44nguvc0T6JCQpWw5Sgx5YPdudj lc8A== X-Gm-Message-State: ALoCoQmbLzbUBnI1Wje5KweGZvzECjMB7vrHJCtSqixpp16gzomkaZEAT6cySLpLN34j9cC6gUVo X-Received: by 10.66.217.164 with SMTP id oz4mr42280381pac.155.1423610164964; Tue, 10 Feb 2015 15:16:04 -0800 (PST) MIME-Version: 1.0 Received: by 10.70.127.195 with HTTP; Tue, 10 Feb 2015 15:15:44 -0800 (PST) In-Reply-To: <1423600163.4947.86.camel@bordewijk.wildebeest.org> References: <1422185341-20243-1-git-send-email-mjw@redhat.com> <20150129080018.GH5193@adacore.com> <1422535409.4947.5.camel@bordewijk.wildebeest.org> <1423070384.4947.47.camel@bordewijk.wildebeest.org> <20150204180550.GC4738@adacore.com> <1423079956.4947.52.camel@bordewijk.wildebeest.org> <1423600163.4947.86.camel@bordewijk.wildebeest.org> From: Patrick Palka Date: Tue, 10 Feb 2015 23:16:00 -0000 Message-ID: Subject: Re: [PATCH] Merge GCC producer parsers. Allow digits in identifiers. To: Mark Wielaard Cc: Joel Brobecker , "gdb-patches@sourceware.org" Content-Type: text/plain; charset=UTF-8 X-SW-Source: 2015-02/txt/msg00279.txt.bz2 On Tue, Feb 10, 2015 at 3:29 PM, Mark Wielaard wrote: > On Wed, 2015-02-04 at 20:59 +0100, Mark Wielaard wrote: >> On Wed, 2015-02-04 at 22:05 +0400, Joel Brobecker wrote: >> > > How about the following cleanup: >> > > >> > > Change producer_is_gcc function return type to bool. >> > > >> > > gdb/ChangeLog: >> > > >> > > * utils.h (producer_is_gcc): Change return type to bool. Add major >> > > argument. >> > > * utils.c (producer_is_gcc): Likewise. >> > > (producer_is_gcc_ge_4): Adjust producer_is_gcc call. >> > > * dwarf2read.c (check_producer): Likewise. >> > >> > It looks really great, thanks for doing that! >> > >> > I have few very minor nits to report (see below), and also I'm wincing >> > a bit at the use of type bool. This is the first use in GDB, and >> > while I don't see that as a problem, and will pre-approve this patch, >> > let's have this patch sit for a week to give people the opportunity >> > to comment before we push it. >> >> OK. I added the 3 empty lines (don't want ARI yelling at me) and will >> push next week. > > I pushed this now. > > Thanks, > > Mark Now that producer_is_gcc() returns a bool, shouldn't the statement 'return -1' become 'return false;', and the statement 'return major;' become 'return true;'? As it stands the function now always returns true since both '(bool)-1' and '(bool)major' evaluate to true, I think.