public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
From: jkratoch@sourceware.org
To: archer-commits@sourceware.org
Subject: [SCM]  archer-jankratochvil-python: Merge commit 'origin/archer-tromey-python' into archer-jankratochvil-python
Date: Tue, 03 Mar 2009 21:46:00 -0000	[thread overview]
Message-ID: <20090303214658.18932.qmail@sourceware.org> (raw)

The branch, archer-jankratochvil-python has been updated
       via  b7d72995b3fb6e6ef1ca3d5cf33269dc523a561f (commit)
       via  2c02a8f709f15aa25a10fb47a9e3bd98ff9d9a78 (commit)
      from  f3ec9b4195a8b4b4de2c513841f469553d9f3b38 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit b7d72995b3fb6e6ef1ca3d5cf33269dc523a561f
Merge: f3ec9b4195a8b4b4de2c513841f469553d9f3b38 2c02a8f709f15aa25a10fb47a9e3bd98ff9d9a78
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Mar 3 22:46:29 2009 +0100

    Merge commit 'origin/archer-tromey-python' into archer-jankratochvil-python

-----------------------------------------------------------------------

Summary of changes:
 gdb/doc/gdb.texinfo                       |    2 +-
 gdb/python/lib/gdb/command/backtrace.py   |    2 +-
 gdb/python/python-frame.c                 |    8 ++++----
 gdb/testsuite/gdb.python/find.exp         |   14 +++++++-------
 gdb/testsuite/gdb.python/python-frame.exp |    6 +++---
 5 files changed, 16 insertions(+), 16 deletions(-)

First 500 lines of diff:
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 8e259f8..dc8d2c1 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -19594,7 +19594,7 @@ Return the frame immediately newer (inner) to this frame.
 Return the frame's symtab and line object. @c (see @xref{Symtab_and_line,, Symtab and line}).
 @end defmethod
 
-@defmethod Frame read_var_value @var{variable}
+@defmethod Frame read_var @var{variable}
 Return the value of the given variable in this frame.  @code{variable} can be
 either a string or a @code{gdb.Symbol} object. @c (@pxref{Symbols In Python}).
 @end defmethod
diff --git a/gdb/python/lib/gdb/command/backtrace.py b/gdb/python/lib/gdb/command/backtrace.py
index 008e5dd..f07696e 100644
--- a/gdb/python/lib/gdb/command/backtrace.py
+++ b/gdb/python/lib/gdb/command/backtrace.py
@@ -33,7 +33,7 @@ class FrameWrapper:
 
         stream.write (sym.print_name + "=")
         try:
-            val = self.frame.read_var_value (sym)
+            val = self.frame.read_var (sym)
             if val != None:
                 val = str (val)
         # FIXME: would be nice to have a more precise exception here.
diff --git a/gdb/python/python-frame.c b/gdb/python/python-frame.c
index 1729717..c98dc39 100644
--- a/gdb/python/python-frame.c
+++ b/gdb/python/python-frame.c
@@ -391,13 +391,13 @@ frapy_find_sal (PyObject *self, PyObject *args)
   return sal_obj;
 }
 
-/* Implementation of gdb.Frame.read_var_value (self, variable) -> gdb.Value.
+/* Implementation of gdb.Frame.read_var (self, variable) -> gdb.Value.
    Returns the value of the given variable in this frame.  The argument can be
    either a gdb.Symbol or a string.  Returns None if GDB can't find the
    specified variable.  */
 
 static PyObject *
-frapy_read_var_value (PyObject *self, PyObject *args)
+frapy_read_var (PyObject *self, PyObject *args)
 {
   struct frame_info *frame;
   PyObject *sym_obj;
@@ -645,8 +645,8 @@ Return the frame immetidaely newer (inner) to this frame." },
   { "find_sal", frapy_find_sal, METH_NOARGS,
     "find_sal () -> gdb.Symtab_and_line.\n\
 Return the frame's symtab and line." },
-  { "read_var_value", frapy_read_var_value, METH_VARARGS,
-    "read_var_value (variable) -> gdb.Value.\n\
+  { "read_var", frapy_read_var, METH_VARARGS,
+    "read_var (variable) -> gdb.Value.\n\
 Return the value of the variable in this frame." },
   {NULL}  /* Sentinel */
 };
diff --git a/gdb/testsuite/gdb.python/find.exp b/gdb/testsuite/gdb.python/find.exp
index a7dad97..dd9aabc 100644
--- a/gdb/testsuite/gdb.python/find.exp
+++ b/gdb/testsuite/gdb.python/find.exp
@@ -90,7 +90,7 @@ set two_patterns_found "${newline}.${dec_number}L, ${dec_number}L]"
 # Test string pattern.
 
 gdb_test "set *(int32_t*) &int8_search_buf\[10\] = 0x61616161" "" ""
-gdb_test "py search_buf = gdb.selected_frame ().read_var_value ('int8_search_buf')" "" ""
+gdb_test "py search_buf = gdb.selected_frame ().read_var ('int8_search_buf')" "" ""
 gdb_test "py start_addr = search_buf.address ()" "" ""
 gdb_test "py length = search_buf.type ().sizeof ()" "" ""
 
@@ -128,7 +128,7 @@ gdb_test "py print gdb.search_memory (start_addr, length, \['a', 'a'\], max_coun
 # Test 16-bit pattern.
 
 gdb_test "set int16_search_buf\[10\] = 0x1234" "" ""
-gdb_test "py search_buf = gdb.selected_frame ().read_var_value ('int16_search_buf')" "" ""
+gdb_test "py search_buf = gdb.selected_frame ().read_var ('int16_search_buf')" "" ""
 gdb_test "py start_addr = search_buf.address ()" "" ""
 gdb_test "py length = search_buf.type ().sizeof ()" "" ""
 gdb_test "py pattern = gdb.parse_and_eval ('(int16_t) 0x1234')" "" ""
@@ -142,7 +142,7 @@ gdb_test "py print gdb.search_memory (start_addr, length, pattern)" \
 # Test 32-bit pattern.
 
 gdb_test "set int32_search_buf\[10\] = 0x12345678" "" ""
-gdb_test "py search_buf = gdb.selected_frame ().read_var_value ('int32_search_buf')" "" ""
+gdb_test "py search_buf = gdb.selected_frame ().read_var ('int32_search_buf')" "" ""
 gdb_test "py start_addr = search_buf.address ()" "" ""
 gdb_test "py length = search_buf.type ().sizeof ()" "" ""
 gdb_test "py pattern = gdb.parse_and_eval ('(int32_t) 0x12345678')" "" ""
@@ -155,7 +155,7 @@ gdb_test "py print gdb.search_memory (start_addr, length, pattern)" \
 # Test 64-bit pattern.
 
 gdb_test "set int64_search_buf\[10\] = 0xfedcba9876543210LL" "" ""
-gdb_test "py search_buf = gdb.selected_frame ().read_var_value ('int64_search_buf')" "" ""
+gdb_test "py search_buf = gdb.selected_frame ().read_var ('int64_search_buf')" "" ""
 gdb_test "py start_addr = search_buf.address ()" "" ""
 gdb_test "py length = search_buf.type ().sizeof ()" "" ""
 gdb_test "py pattern = gdb.parse_and_eval ('(int64_t) 0xfedcba9876543210LL')" "" ""
@@ -170,7 +170,7 @@ gdb_test "py print gdb.search_memory (start_addr, length, pattern)" \
 gdb_test "set *(int8_t*) &search_buf\[10\] = 0x62" "" ""
 gdb_test "set *(int16_t*) &search_buf\[11\] = 0x6363" "" ""
 gdb_test "set *(int32_t*) &search_buf\[13\] = 0x64646464" "" ""
-gdb_test "py search_buf = gdb.selected_frame ().read_var_value ('search_buf')" "" ""
+gdb_test "py search_buf = gdb.selected_frame ().read_var ('search_buf')" "" ""
 gdb_test "py start_addr = search_buf\[0\].address ()" "" ""
 gdb_test "py pattern1 = gdb.parse_and_eval ('(int8_t) 0x62')" "" ""
 gdb_test "py pattern2 = gdb.parse_and_eval ('(int16_t) 0x6363')" "" ""
@@ -187,8 +187,8 @@ set CHUNK_SIZE 16000 ;
 
 gdb_test "set *(int32_t*) &search_buf\[0*${CHUNK_SIZE}+100\] = 0x12345678" "" ""
 gdb_test "set *(int32_t*) &search_buf\[1*${CHUNK_SIZE}+100\] = 0x12345678" "" ""
-gdb_test "py start_addr = gdb.selected_frame ().read_var_value ('search_buf')" "" ""
-gdb_test "py length = gdb.selected_frame ().read_var_value ('search_buf_size')" "" ""
+gdb_test "py start_addr = gdb.selected_frame ().read_var ('search_buf')" "" ""
+gdb_test "py length = gdb.selected_frame ().read_var ('search_buf_size')" "" ""
 
 gdb_test "py print gdb.search_memory (start_addr, length, 0x12345678, 4)" \
   "${two_patterns_found}" "search spanning large range"
diff --git a/gdb/testsuite/gdb.python/python-frame.exp b/gdb/testsuite/gdb.python/python-frame.exp
index f62f63d..083fa90 100644
--- a/gdb/testsuite/gdb.python/python-frame.exp
+++ b/gdb/testsuite/gdb.python/python-frame.exp
@@ -81,10 +81,10 @@ gdb_test "python print 'result =', f0.pc ()" " = \[0-9\]+" "test Frame.pc"
 gdb_test "python print 'result =', f0.addr_in_block ()" " = \[0-9\]+" "test Frame.addr_in_block"
 gdb_test "python print 'result =', f0.older ().equals (f1)" " = True" "test Frame.older"
 gdb_test "python print 'result =', f1.newer ().equals (f0)" " = True" "test Frame.newer"
-gdb_test "python print 'result =', f0.read_var_value ('b')" \
+gdb_test "python print 'result =', f0.read_var ('b')" \
   "ValueError: variable 'b' not found.*Error while executing Python code." \
-  "test Frame.read_var_value - error"
-gdb_test "python print 'result =', f0.read_var_value ('a')" " = 1" "test Frame.read_var_value - success"
+  "test Frame.read_var - error"
+gdb_test "python print 'result =', f0.read_var ('a')" " = 1" "test Frame.read_var - success"
 
 gdb_test "python print 'result =', gdb.newest_frame ().equals (f0)" " = True" "test gdb.newest_frame"
 gdb_test "python print 'result =', gdb.selected_frame ().equals (f1)" " = True" "test gdb.selected_frame"


hooks/post-receive
--
Repository for Project Archer.


             reply	other threads:[~2009-03-03 21:46 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-03 21:46 jkratoch [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-06-26 13:51 jkratoch
2009-03-30 17:22 jkratoch
2009-03-29 22:42 jkratoch
2009-03-27  0:35 jkratoch
2009-03-25 19:00 jkratoch
2009-03-24 17:33 jkratoch
2009-03-09 17:05 jkratoch
2009-03-06 16:59 jkratoch
2009-03-06 14:26 jkratoch
2009-03-05 21:53 jkratoch
2009-03-05 21:15 jkratoch
2009-03-04 23:54 jkratoch
2009-03-04 22:34 jkratoch
2009-03-04 15:02 jkratoch
2009-03-03 21:45 jkratoch
2009-03-02 20:46 jkratoch
2009-03-01 14:38 jkratoch
2009-02-28 19:26 jkratoch
2009-02-26 23:01 jkratoch

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=20090303214658.18932.qmail@sourceware.org \
    --to=jkratoch@sourceware.org \
    --cc=archer-commits@sourceware.org \
    /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).