This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch/rfc] Generate observer.[hc]


On Thu, Apr 08, 2004 at 05:09:34PM -0400, Andrew Cagney wrote:

Hello,

The attached adds the script observer.sh that can be used to generate:
	observer.h
	observer.ch (#included by observer.c)
aat build time using doc/observer.texi as the input.

While this is more ambitious than gdbarch.* (which are explicitly generated and then committed to CVS) I suspect it is prefered.

Comments?

Once this is in I can add a few observers, and start deleting all those hooks and events.


I like it, and the patch looks fine to me.  My only complaint is that I
don't much like the .ch suffix.  But then, using .c is probably pretty
confusing too, so I don't have a better idea - I won't complain.

So far I've been through .hh .cc .hc .ch ....


-@deftypefun extern struct observer *observer_attach_normal_stop (observer_normal_stop_ftype *@var{f})


Also, my instinct when reading this manual would be to just remove
these obsolete "extern"s.  Which would break the script, since it would
try to generate an event for observer_detach_@var{event}.  So I think
that either that should be fixed or there should be a comment somewhere
to leave them in.

Oops, thats the wrong example, try:


+@deftypefun void normal_stop (struct bpstats *@var{bs})

(yes the externs can go)

Andrew



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]