This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] gdb: Remove duplicate declaration of global innermost_block


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=396af9a1527b396c251e70b5c79b5fc83fd1d7ff

commit 396af9a1527b396c251e70b5c79b5fc83fd1d7ff
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Wed Oct 18 19:04:17 2017 +0100

    gdb: Remove duplicate declaration of global innermost_block
    
    The global 'innermost_block' is declared in two header files.  Remove
    one of the declarations, and add an include of the other header into
    the one source file that could no longer see a declaration of
    'innermost_block'.
    
    gdb/ChangeLog:
    
    	* expression.h (innermost_block): Remove declaration.
    	* varobj.c: Add 'parser-defs.h' include.

Diff:
---
 gdb/ChangeLog    | 5 +++++
 gdb/expression.h | 5 -----
 gdb/varobj.c     | 1 +
 3 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d2d4472..a346ddd 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+	* expression.h (innermost_block): Remove declaration.
+	* varobj.c: Add 'parser-defs.h' include.
+
 2018-01-19  Tom Tromey  <tom@tromey.com>
 
 	* rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
diff --git a/gdb/expression.h b/gdb/expression.h
index a783ea5..030f2f0 100644
--- a/gdb/expression.h
+++ b/gdb/expression.h
@@ -111,11 +111,6 @@ extern expression_up parse_exp_1 (const char **, CORE_ADDR pc,
    attempt completion.  */
 extern int parse_completion;
 
-/* The innermost context required by the stack and register variables
-   we've encountered so far.  To use this, set it to NULL, then call
-   parse_<whatever>, then look at it.  */
-extern const struct block *innermost_block;
-
 /* From eval.c */
 
 /* Values of NOSIDE argument to eval_subexp.  */
diff --git a/gdb/varobj.c b/gdb/varobj.c
index 01dabef..701ef66 100644
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -30,6 +30,7 @@
 #include "gdbthread.h"
 #include "inferior.h"
 #include "varobj-iter.h"
+#include "parser-defs.h"
 
 #if HAVE_PYTHON
 #include "python/python.h"


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]