diff options
Diffstat (limited to 'gdb/dwarf2/ada-imported.c')
-rw-r--r-- | gdb/dwarf2/ada-imported.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gdb/dwarf2/ada-imported.c b/gdb/dwarf2/ada-imported.c index 9ec0d51..1e25966 100644 --- a/gdb/dwarf2/ada-imported.c +++ b/gdb/dwarf2/ada-imported.c @@ -1,6 +1,6 @@ /* Ada Pragma Import support. - Copyright (C) 2023-2024 Free Software Foundation, Inc. + Copyright (C) 2023-2025 Free Software Foundation, Inc. This file is part of GDB. @@ -20,6 +20,7 @@ #include "symtab.h" #include "value.h" #include "dwarf2/loc.h" +#include "objfiles.h" /* Helper to get the imported symbol's real name. */ static const char * @@ -34,7 +35,9 @@ static struct value * ada_imported_read_variable (struct symbol *symbol, const frame_info_ptr &frame) { const char *name = get_imported_name (symbol); - bound_minimal_symbol minsym = lookup_minimal_symbol_linkage (name, false); + bound_minimal_symbol minsym + = lookup_minimal_symbol_linkage (symbol->objfile ()->pspace (), name, + true, false); if (minsym.minsym == nullptr) error (_("could not find imported name %s"), name); return value_at (symbol->type (), minsym.value_address ()); |