aboutsummaryrefslogtreecommitdiff
path: root/gdb/inferior.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2020-10-29 15:04:33 -0600
committerTom Tromey <tom@tromey.com>2020-10-29 15:04:38 -0600
commit004eecfdc7d9b47e8364719667c64edb22d12d44 (patch)
treee07c8b72a4dacff3b87850f2711ea06163c087be /gdb/inferior.c
parente39fb97114f28dbc0f38a9851437437bfc5c43a0 (diff)
downloadgdb-004eecfdc7d9b47e8364719667c64edb22d12d44.zip
gdb-004eecfdc7d9b47e8364719667c64edb22d12d44.tar.gz
gdb-004eecfdc7d9b47e8364719667c64edb22d12d44.tar.bz2
Change program_space_empty_p to method on program_space
This changes program_space_empty_p to be a method on program_space. It also changes it to return bool. I removed the "_p" suffix because "empty" is a "well-known" C++ method name. gdb/ChangeLog 2020-10-29 Tom Tromey <tom@tromey.com> * inferior.c (delete_inferior): Update. * progspace.c (program_space::empty): Rename from program_space_empty_p. Return bool. * progspace.h (struct program_space) <empty>: New method. (program_space_empty_p): Don't declare.
Diffstat (limited to 'gdb/inferior.c')
-rw-r--r--gdb/inferior.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/inferior.c b/gdb/inferior.c
index fc21241..12f4de4 100644
--- a/gdb/inferior.c
+++ b/gdb/inferior.c
@@ -175,7 +175,7 @@ delete_inferior (struct inferior *todel)
gdb::observers::inferior_removed.notify (inf);
/* If this program space is rendered useless, remove it. */
- if (program_space_empty_p (inf->pspace))
+ if (inf->pspace->empty ())
delete inf->pspace;
delete inf;