From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cagney To: GDB Patches , Insight Patches Subject: Re: [fyi] fix gdb's regcache.h depedencies Date: Thu, 01 Mar 2001 08:14:00 -0000 Message-id: <3A9E74CB.D849416E@cygnus.com> References: <3A9E6EB1.76A80113@cygnus.com> X-SW-Source: 2001-03/msg00011.html And the following, it isn't my day :-( Andrew 2001-03-01 Andrew Cagney * Makefile.in (gdbtk-cmds.o): Add $(regcache_h) to dependency lists. (mi-main.o): Ditto. Index: Makefile.in =================================================================== RCS file: /cvs/src/src/gdb/Makefile.in,v retrieving revision 1.64 diff -p -r1.64 Makefile.in *** Makefile.in 2001/03/01 15:49:13 1.64 --- Makefile.in 2001/03/01 16:08:57 *************** gdbtk-cmds.o: $(srcdir)/gdbtk/generic/gd *** 1411,1417 **** $(srcdir)/gdbtk/generic/gdbtk.h \ $(defs_h) $(symtab_h) $(inferior_h) \ $(command_h) $(bfd_h) $(top_h) symfile.h objfiles.h target.h \ ! gdb_string.h $(tracepoint_h) $(frame_h) source.h $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) \ $(TIX_CFLAGS) $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) \ $(GDBTK_CFLAGS) $(srcdir)/gdbtk/generic/gdbtk-cmds.c \ --- 1411,1417 ---- $(srcdir)/gdbtk/generic/gdbtk.h \ $(defs_h) $(symtab_h) $(inferior_h) \ $(command_h) $(bfd_h) $(top_h) symfile.h objfiles.h target.h \ ! gdb_string.h $(tracepoint_h) $(frame_h) source.h $(regcache_h) $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) \ $(TIX_CFLAGS) $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) \ $(GDBTK_CFLAGS) $(srcdir)/gdbtk/generic/gdbtk-cmds.c \ *************** mi-cmd-disas.o: $(srcdir)/mi/mi-cmd-disa *** 2143,2149 **** $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-cmd-disas.c mi-main.o: $(srcdir)/mi/mi-main.c $(defs_h) $(top_h) $(mi_cmds_h) $(ui_out_h) \ $(mi_console_h) $(mi_getopt_h) $(event_loop_h) $(event_top_h) \ ! $(mi_getopt_h) $(CC) -c $(INTERNAL_WARN_CFLAGS) $(srcdir)/mi/mi-main.c mi-out.o: $(srcdir)/mi/mi-out.c $(defs_h) $(mi_out_h) $(ui_out_h) $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-out.c --- 2143,2149 ---- $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-cmd-disas.c mi-main.o: $(srcdir)/mi/mi-main.c $(defs_h) $(top_h) $(mi_cmds_h) $(ui_out_h) \ $(mi_console_h) $(mi_getopt_h) $(event_loop_h) $(event_top_h) \ ! $(mi_getopt_h) $(regcache_h) $(CC) -c $(INTERNAL_WARN_CFLAGS) $(srcdir)/mi/mi-main.c mi-out.o: $(srcdir)/mi/mi-out.c $(defs_h) $(mi_out_h) $(ui_out_h) $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-out.c >From ac131313@cygnus.com Thu Mar 01 09:06:00 2001 From: Andrew Cagney To: Mark Kettenis , gdb-patches@sourceware.cygnus.com Subject: Re: [PATCH] GDB friendly assert Date: Thu, 01 Mar 2001 09:06:00 -0000 Message-id: <3A9E8109.3D6A8B0C@cygnus.com> References: <200009031729.e83HTgg00915@delius.kettenis.local> <39F584B7.A87D796F@cygnus.com> <200010241526.e9OFQJK06503@debye.wins.uva.nl> <3A06976F.DFB0F373@cygnus.com> X-SW-Source: 2001-03/msg00012.html Content-length: 1053 Andrew Cagney wrote: > > Mark Kettenis wrote: > > > > Date: Tue, 24 Oct 2000 23:46:47 +1100 > > From: Andrew Cagney > > > > Thanks! Good move. > > > > My only (A.R.) thought is to make the macro upper case so it is very > > clear to developers that they are using a MACRO and not a function. > > > > Hmm, my idea was that it simply is the standard assert() (which > > typically is a macro) with gdb_ prepended. > > Yes, I know. I'm trying to trade off ``MACRO's are upper case'' against > ``assert()'' in lower-case is more consistent with STDC even if it was a > bad idea. > > > But if you feel it should > > be changed into GDB_ASSERT, I'll be happy to change it. > > I don't know :-) To close this, I'm going to add a comment to "gdb_assert.h" noting that there is a tradeoff between these two. lcase was chosen as it is closer to the existing UNIX convention. As a btw, people adding new code may want to use gdb_assert() in preference to internal error. It is shorter and more convenient. Andrew