gdb/python: Introduce gdb.lookup_all_static_symbols

Message ID 20191023191528.GI4962@embecosm.com
State New, archived
Headers

Commit Message

Andrew Burgess Oct. 23, 2019, 7:15 p.m. UTC
  * Eli Zaretskii <eliz@gnu.org> [2019-10-15 20:07:41 +0300]:

> > From: Andrew Burgess <andrew.burgess@embecosm.com>
> > Cc: Christian Biesinger <cbiesinger@google.com>,	Andrew Burgess <andrew.burgess@embecosm.com>
> > Date: Tue, 15 Oct 2019 17:46:47 +0100
> > 
> > gdb/ChangeLog:
> > 
> > 	* python/py-symbol.c (gdbpy_lookup_all_static_symbols): New
> > 	function.
> > 	* python/python-internal.h (gdbpy_lookup_all_static_symbols):
> > 	Declare new function.
> > 	* python/python.c (python_GdbMethods): Add
> > 	gdb.lookup_all_static_symbols method.
> > 
> > gdb/testsuite/ChangeLog:
> > 
> > 	* gdb.python/py-symbol.exp: Add test for
> > 	gdb.lookup_all_static_symbols.
> > 
> > gdb/doc/ChangeLog:
> > 
> > 	* python.texi (Symbols In Python): Add documentation for
> > 	gdb.lookup_all_static_symbols.
> 
> The python.texi part is OK, but I think this change also needs a NEWS
> entry.

Thanks for the review, I'll include the NEWS entry below when I merge
this patch.

Thanks,
Andrew

--
  

Comments

Eli Zaretskii Oct. 24, 2019, 2:31 a.m. UTC | #1
> Date: Wed, 23 Oct 2019 20:15:28 +0100
> From: Andrew Burgess <andrew.burgess@embecosm.com>
> Cc: gdb-patches@sourceware.org, cbiesinger@google.com
> 
> diff --git a/gdb/NEWS b/gdb/NEWS
> index 25e67e43c88..465f96aed18 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -65,6 +65,9 @@
>    ** The new function gdb.lookup_static_symbol can be used to look up
>       symbols with static linkage.
>  
> +  ** The new function gdb.lookup_static_symbols can be used to look up
> +     all static symbols with static linkage.
> +

OK.
  

Patch

diff --git a/gdb/NEWS b/gdb/NEWS
index 25e67e43c88..465f96aed18 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -65,6 +65,9 @@ 
   ** The new function gdb.lookup_static_symbol can be used to look up
      symbols with static linkage.
 
+  ** The new function gdb.lookup_static_symbols can be used to look up
+     all static symbols with static linkage.
+
   ** gdb.Objfile has new methods 'lookup_global_symbol' and
      'lookup_static_symbol' to lookup a symbol from this objfile only.