public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: gdb-patches@sourceware.org
Cc: Simon Marchi <simon.marchi@efficios.com>
Subject: [PATCH 1/8] gdb: add program_space parameter to ada_clear_symbol_cache
Date: Tue,  3 Oct 2023 22:20:16 -0400	[thread overview]
Message-ID: <20231004022305.298534-2-simon.marchi@polymtl.ca> (raw)
In-Reply-To: <20231004022305.298534-1-simon.marchi@polymtl.ca>

From: Simon Marchi <simon.marchi@efficios.com>

Make the references to current_program_space bubble up one level.

Change-Id: I82acab5628c30f6535d52aa32ce2c1d0375cbeed
---
 gdb/ada-lang.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index 53d53e0ffa58..4dc405580645 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -4673,9 +4673,9 @@ make_array_descriptor (struct type *type, struct value *arr)
 /* Clear all entries from the symbol cache.  */
 
 static void
-ada_clear_symbol_cache ()
+ada_clear_symbol_cache (program_space *pspace)
 {
-  ada_pspace_data_handle.clear (current_program_space);
+  ada_pspace_data_handle.clear (pspace);
 }
 
 /* Search the symbol cache for an entry matching NAME and DOMAIN.
@@ -13884,7 +13884,7 @@ static struct cmd_list_element *show_ada_list;
 static void
 ada_new_objfile_observer (struct objfile *objfile)
 {
-  ada_clear_symbol_cache ();
+  ada_clear_symbol_cache (current_program_space);
 }
 
 /* This module's 'free_objfile' observer.  */
@@ -13892,7 +13892,7 @@ ada_new_objfile_observer (struct objfile *objfile)
 static void
 ada_free_objfile_observer (struct objfile *objfile)
 {
-  ada_clear_symbol_cache ();
+  ada_clear_symbol_cache (current_program_space);
 }
 
 /* Charsets known to GNAT.  */
-- 
2.42.0


  reply	other threads:[~2023-10-04  2:23 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-04  2:20 [PATCH 0/8] Split new_objfile observable Simon Marchi
2023-10-04  2:20 ` Simon Marchi [this message]
2023-10-04  2:20 ` [PATCH 2/8] gdb: add program_space parameters to some functions in symtab.c Simon Marchi
2023-10-04  2:20 ` [PATCH 3/8] gdb: add program_space parameter to emit_clear_objfiles_event Simon Marchi
2023-10-04  2:20 ` [PATCH 4/8] gdb: use objfile->pspace in auto-load.c Simon Marchi
2023-10-04  2:20 ` [PATCH 5/8] gdb: add program_space parameters to some auto-load functions Simon Marchi
2023-10-04  2:20 ` [PATCH 6/8] gdb: add all_objfiles_removed observer Simon Marchi
2023-10-05 16:35   ` Tom Tromey
2023-10-05 17:13     ` Simon Marchi
2023-10-04  2:20 ` [PATCH 7/8] gdb: remove unnecessary nullptr check in free_objfile observers Simon Marchi
2023-10-04  2:20 ` [PATCH 8/8] gdb: use objfile->pspace " Simon Marchi
2023-10-05 16:36 ` [PATCH 0/8] Split new_objfile observable Tom Tromey
2023-10-05 17:23   ` Simon Marchi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231004022305.298534-2-simon.marchi@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@efficios.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).