From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12885 invoked by alias); 11 Mar 2002 00:20:39 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 12796 invoked from network); 11 Mar 2002 00:20:37 -0000 Received: from unknown (HELO nevyn.them.org) (128.2.145.6) by sources.redhat.com with SMTP; 11 Mar 2002 00:20:37 -0000 Received: from drow by nevyn.them.org with local (Exim 3.35 #1 (Debian)) id 16kDYM-0003i4-00; Sun, 10 Mar 2002 19:20:38 -0500 Date: Sun, 10 Mar 2002 16:20:00 -0000 From: Daniel Jacobowitz To: Andrew Cagney Cc: gdb-patches@sources.redhat.com Subject: Re: [rfa] Always define all of TARGET_SIGNAL_* Message-ID: <20020310192038.A14083@nevyn.them.org> Mail-Followup-To: Andrew Cagney , gdb-patches@sources.redhat.com References: <20020227221148.A30753@nevyn.them.org> <3C7E456C.6090605@cygnus.com> <20020228115139.A8496@nevyn.them.org> <3C7E6634.4010209@cygnus.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3C7E6634.4010209@cygnus.com> User-Agent: Mutt/1.3.23i X-SW-Source: 2002-03/txt/msg00154.txt.bz2 On Thu, Feb 28, 2002 at 12:17:40PM -0500, Andrew Cagney wrote: > >On Thu, Feb 28, 2002 at 09:57:48AM -0500, Andrew Cagney wrote: > > > >>>I've been meaning to fix this since I noticed it last summer. These > >>>numbers > >>>are part of the remote protocol. While I think the last ones are never > >>>sent > >>>over the wire, they could be (with the exception of TARGET_SIGNAL_LAST > >>>which > >>>is -not- part of the protocol, as I understand it). Having them jump > >>>around > >>>is bad. > > > >> > >>Wasn't this enum going to be moved to signals.h? > > > > > >I think so, but I didn't see any pressing reason to. If you want, I > >can do that. > > > >OK otherwise? > > I'd leave it until after things branch and then fix it properly in the > trunk. Now that we've got a "gdb/signals.h", there's a place to fix this properly in the trunk. How does this patch look? -- Daniel Jacobowitz Carnegie Mellon University MontaVista Software Debian GNU/Linux Developer 2002-03-10 Daniel Jacobowitz * signals.h: Update comments. (enum target_signal): Remove conditional compilation around Mach-specific signals. Index: signals.h =================================================================== RCS file: /cvs/src/src/include/gdb/signals.h,v retrieving revision 1.1 diff -u -p -r1.1 signals.h --- signals.h 2002/03/11 00:01:11 1.1 +++ signals.h 2002/03/11 00:20:15 @@ -32,7 +32,8 @@ Since these numbers have actually made it out into other software (stubs, etc.), you mustn't disturb the assigned numbering. If you need to add new signals here, add them to the end of the explicitly - numbered signals. + numbered signals, at the comment marker. Add them unconditionally, + not within any #if or #ifdef. This is based strongly on Unix/POSIX signals for several reasons: (1) This set of signals represents a widely-accepted attempt to @@ -208,7 +209,6 @@ enum target_signal TARGET_SIGNAL_REALTIME_126, TARGET_SIGNAL_REALTIME_127, -#if defined(MACH) || defined(__MACH__) /* Mach exceptions */ TARGET_EXC_BAD_ACCESS, TARGET_EXC_BAD_INSTRUCTION, @@ -216,7 +216,7 @@ enum target_signal TARGET_EXC_EMULATION, TARGET_EXC_SOFTWARE, TARGET_EXC_BREAKPOINT, -#endif + TARGET_SIGNAL_INFO, /* Some signal we don't know about. */ @@ -225,6 +225,8 @@ enum target_signal /* Use whatever signal we use when one is not specifically specified (for passing to proceed and so on). */ TARGET_SIGNAL_DEFAULT, + + /* If you are adding a new signal, add it just above this comment. */ /* Last and unused enum value, for sizing arrays, etc. */ TARGET_SIGNAL_LAST