From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 56672 invoked by alias); 12 Apr 2016 17:21:26 -0000 Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org Received: (qmail 56655 invoked by uid 89); 12 Apr 2016 17:21:25 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: paperclip.tbsaunde.org Received: from tbsaunde.org (HELO paperclip.tbsaunde.org) (66.228.47.254) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 12 Apr 2016 17:21:24 +0000 Received: from ball (unknown [IPv6:2607:f0c8:8000:80e0:56ee:75ff:fe52:afb9]) by paperclip.tbsaunde.org (Postfix) with ESMTPSA id 499C3C06F; Tue, 12 Apr 2016 17:21:23 +0000 (UTC) Date: Tue, 12 Apr 2016 17:21:00 -0000 From: Trevor Saunders To: Nick Clifton Cc: tbsaunde+binutils@tbsaunde.org, binutils@sourceware.org Subject: Re: [PATCH] remove some unused globals Message-ID: <20160412172613.GB7748@ball> References: <1460469895-14787-1-git-send-email-tbsaunde+binutils@tbsaunde.org> <570D2166.9040405@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <570D2166.9040405@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SW-Source: 2016-04/txt/msg00186.txt.bz2 On Tue, Apr 12, 2016 at 05:25:10PM +0100, Nick Clifton wrote: > Hi Trev, > > > $subject, built crosses to msp430-elf and m32c-elf, ok? > > If you make these enums anonymous, doesn't that make them harder to use/reference from a debugger ? I'm not sure I follow, these enums have always been anonymous in the sense you can't name there type. So it used to be we declared a set of constants in the { } and then declared a variable of some anonymous enum type, but then we never used that variable and only used the enum constants with other variables. So I expect the only difference this makes to debugging is that you can't refer to a variable that doesn't exist, but since that variable never does anything examining it seems pointless. Now it may well be that naming these types, and changing some variables from type int to the enum type would improve debugging by getting gdb to just print the constant name, but I don't think anything is regressed here. Looking a little deeper it seems like in the msp430 it might be clearer to just use a bool or something. Thanks! Trev > > Cheers > Nick