+2001-11-30 Pierre Muller <muller@ics.u-strasbg.fr>
+
+ * findvar.c (locate_var_value): Specify in which register a register
+ variable is stored.
+
2001-11-30 Pierre Muller <muller@ics.u-strasbg.fr>
* win32-nat.c (mappings): Correct position of XMM registers,
#include "inferior.h"
#include "target.h"
#include "gdb_string.h"
+#include "gdb_assert.h"
#include "floatformat.h"
#include "symfile.h" /* for overlay functions */
#include "regcache.h"
switch (VALUE_LVAL (lazy_value))
{
case lval_register:
+ gdb_assert (REGISTER_NAME (VALUE_REGNO (lazy_value)) != NULL
+ && *REGISTER_NAME (VALUE_REGNO (lazy_value)) != '\0');
+ error("Address requested for identifier "
+ "\"%s\" which is in register $%s",
+ SYMBOL_SOURCE_NAME (var),
+ REGISTER_NAME (VALUE_REGNO (lazy_value)));
+ break;
+
case lval_reg_frame_relative:
- error ("Address requested for identifier \"%s\" which is in a register.",
- SYMBOL_SOURCE_NAME (var));
+ gdb_assert (REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value)) != NULL
+ && *REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value)) != '\0');
+ error("Address requested for identifier "
+ "\"%s\" which is in frame register $%s",
+ SYMBOL_SOURCE_NAME (var),
+ REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value)));
break;
default: