Add some new subclasses of breakpoint

This adds a few new subclasses of breakpoint.  The inheritance
hierarchy is chosen to reflect what's already present in
initialize_breakpoint_ops -- it mirrors the way that the _ops
structures are filled in.

This patch also changes new_breakpoint_from_type to create the correct
sublcass based on bptype.  This is important due to the somewhat
inverted way in which create_breakpoint works; and in particular later
patches will change some of these entries.
This commit is contained in:
Tom Tromey
2022-01-15 13:37:28 -07:00
parent 779dcceba7
commit 098f12723d
2 changed files with 77 additions and 13 deletions

View File

@ -940,6 +940,13 @@ struct breakpoint
gdbscm_breakpoint_object *scm_bp_object = NULL;
};
/* The structure to be inherit by all kinds of breakpoints (real
breakpoints, i.e., user "break" breakpoints, internal and momentary
breakpoints, etc.). */
struct base_breakpoint : public breakpoint
{
};
/* An instance of this type is used to represent a watchpoint. */
struct watchpoint : public breakpoint