From c7c1b3e998a77eb077ac3c08c88a97d2e11dfef0 Mon Sep 17 00:00:00 2001 From: Keith Seitz Date: Tue, 11 Aug 2015 17:09:35 -0700 Subject: Explicit locations: introduce new struct event_location-based API This patch introduces the new breakpoint/"linespec" API based on a new struct event_location. This API currently only supports traditional linespecs, maintaining the status quo of the code base. Future patches will add additional functionality for other location types such as address locations. gdb/ChangeLog: * Makefile.in (SFILES): Add location.c. (HFILES_NO_SRCDIR): Add location.h. (COMMON_OBS): Add location.o. * linespec.c (linespec_lex_to_end): New function. * linespec.h (linespec_lex_to_end): Declare. * location.c: New file. * location.h: New file. --- gdb/linespec.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gdb/linespec.h') diff --git a/gdb/linespec.h b/gdb/linespec.h index 7e66024..77ec46d 100644 --- a/gdb/linespec.h +++ b/gdb/linespec.h @@ -156,4 +156,9 @@ extern struct symtabs_and_lines decode_line_with_last_displayed (char *, int); the keyword. If not, return NULL. */ extern const char *linespec_lexer_lex_keyword (const char *p); + +/* Find the end of the (first) linespec pointed to by *STRINGP. + STRINGP will be advanced to this point. */ + +extern void linespec_lex_to_end (char **stringp); #endif /* defined (LINESPEC_H) */ -- cgit v1.1