From d6bc0792edf0ef423ee4604bfd4bee49654314bb Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Fri, 15 May 2020 16:24:07 -0600 Subject: Remove lookup_objfile_from_block lookup_objfile_from_block mostly duplicates the functionality of block_objfile, but in a less efficient way. This patch removes this function and changes the callers to use block_objfile instead. Tested by the buildbot. gdb/ChangeLog 2020-05-15 Tom Tromey * symtab.c (lookup_language_this, lookup_symbol_aux): Use block_objfile. (lookup_objfile_from_block): Remove. (lookup_symbol_in_block, lookup_symbol_in_static_block) (lookup_global_symbol): Use block_objfile. * symtab.h (lookup_objfile_from_block): Don't declare. * printcmd.c (clear_dangling_display_expressions): Use block_objfile. * parse.c (operator_check_standard): Use block_objfile. --- gdb/parse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/parse.c') diff --git a/gdb/parse.c b/gdb/parse.c index b4d9005..d5efe4a 100644 --- a/gdb/parse.c +++ b/gdb/parse.c @@ -1340,7 +1340,7 @@ operator_check_standard (struct expression *exp, int pos, return 1; /* Check objfile where is placed the code touching the variable. */ - objfile = lookup_objfile_from_block (block); + objfile = block_objfile (block); type = SYMBOL_TYPE (symbol); } -- cgit v1.1