This is the mail archive of the
gdb@sourceware.cygnus.com
mailing list for the GDB project.
Re: memory region attribute CLI
"J.T. Conklin" wrote:
>
> >>>>> "jtc" == J T Conklin <jtc@redback.com> writes:
> jtc> Yes, I guess it has been a while, hasn't it.
> jtc>
> jtc> Start at:
> jtc> http://sourceware.cygnus.com/ml/gdb/1999-q4/msg00168.html
>
> No comments?
>
> Here's a bit more meat. I've gone ahead and implemented the CLI, and
> would appreciate any comments. I'm planning on writing documentation
> and making the changes to use these attributes this week.
>
> Many thanks,
>
> --jtc
>
> /* memattr.h */
> #ifndef MEMATTR_H
> #define MEMATTR_H
>
> /* FIXME: I stole this bit from tracepoint.h. The definition should
> probably be moved out of breakpoint.h, tracepoint.h, and memattr.h
> and into defs.h or something like that. */
> #if !defined (BREAKPOINT_H)
> enum enable
> {
> disabled, enabled
> };
> #endif
An aside. That enum needs to be taken out and .... I've twice attemted
to purge it but found the efforts lead down a deep dark rat hole - it
has its fingers in everything. Can I suggest adding a little more
violence to the FIXME so that its clear how bad that enum is :-)
Sorry, I just detest that enum :-)
Andrew
It polutes the name space. It isn't FSF compliant. It clases with other
``enable'' and ``enabled'' variables. Code can't include breakpoint.h
because of clashes, ....