public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  archer-tromey-python:  * value.h (value_address): Update comment.
@ 2008-10-17 19:20 tromey
  0 siblings, 0 replies; only message in thread
From: tromey @ 2008-10-17 19:20 UTC (permalink / raw)
  To: archer-commits

The branch, archer-tromey-python has been updated
       via  4d6117a23b69e43cb55641da7a91db00b1747fea (commit)
      from  b9f17e4e3873c74786994bda5daae394d69d7948 (commit)

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

- Log -----------------------------------------------------------------
commit 4d6117a23b69e43cb55641da7a91db00b1747fea
Author: Tom Tromey <tromey@redhat.com>
Date:   Fri Oct 17 13:18:09 2008 -0600

    	* value.h (value_address): Update comment.
    	* value.c (value_address): Return 0 for internalvars.  Don't
    	assert.
    	(value_raw_address): Likewise.

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

Summary of changes:
 gdb/ChangeLog |    7 +++++++
 gdb/value.c   |   10 ++++++----
 gdb/value.h   |    2 +-
 3 files changed, 14 insertions(+), 5 deletions(-)

First 500 lines of diff:
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 9599ad5..0a27243 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,12 @@
 2008-10-17  Tom Tromey  <tromey@redhat.com>
 
+	* value.h (value_address): Update comment.
+	* value.c (value_address): Return 0 for internalvars.  Don't
+	assert.
+	(value_raw_address): Likewise.
+
+2008-10-17  Tom Tromey  <tromey@redhat.com>
+
 	* ada-lang.c, ada-valprint.c, breakpoint.c, c-valprint.c,
 	cli/cli-dump.c, cp-valprint.c, dwarf2loc.c, eval.c, findvar.c,
 	frame.c, frv-tdep.c, gnu-v2-abi.c, gnu-v3-abi.c, infcall.c,
diff --git a/gdb/value.c b/gdb/value.c
index 9493796..d900c5b 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -487,16 +487,18 @@ deprecated_value_lval_hack (struct value *value)
 CORE_ADDR
 value_address (struct value *value)
 {
-  gdb_assert (value->lval != lval_internalvar
-	      && value->lval != lval_internalvar_component);
+  if (value->lval == lval_internalvar
+      || value->lval == lval_internalvar_component)
+    return 0;
   return value->location.address + value->offset;
 }
 
 CORE_ADDR
 value_raw_address (struct value *value)
 {
-  gdb_assert (value->lval != lval_internalvar
-	      && value->lval != lval_internalvar_component);
+  if (value->lval == lval_internalvar
+      || value->lval == lval_internalvar_component)
+    return 0;
   return value->location.address;
 }
 
diff --git a/gdb/value.h b/gdb/value.h
index 7688037..df4c795 100644
--- a/gdb/value.h
+++ b/gdb/value.h
@@ -214,7 +214,7 @@ extern enum lval_type *deprecated_value_lval_hack (struct value *);
 
 /* If lval == lval_memory, return the address in the inferior.  If
    lval == lval_register, return the byte offset into the registers
-   structure.  Otherwise, give an error.  The returned address
+   structure.  Otherwise, return 0.  The returned address
    includes the offset, if any.  */
 extern CORE_ADDR value_address (struct value *);
 


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


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-10-17 19:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-10-17 19:20 [SCM] archer-tromey-python: * value.h (value_address): Update comment tromey

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).