+2014-04-12 Siva Chandra Reddy <sivachandra@google.com>
+ Doug Evans <xdje42@gmail.com>
+
+ * guile/scm-value.c (gdbscm_value_dynamic_type): Use coerce_ref to
+ dereference TYPE_CODE_REF values.
+
2014-04-11 Joel Brobecker <brobecker@adacore.com>
Revert the following changes due to regressions:
struct value *target;
int was_pointer = TYPE_CODE (type) == TYPE_CODE_PTR;
- target = value_ind (value);
+ if (was_pointer)
+ target = value_ind (value);
+ else
+ target = coerce_ref (value);
type = value_rtti_type (target, NULL, NULL, NULL);
if (type)
+2014-04-12 Siva Chandra Reddy <sivachandra@google.com>
+ Doug Evans <xdje42@gmail.com>
+
+ * gdb.guile/scm-value.c: Improve test case.
+ * gdb.guile/scm-value.exp: Add new test.
+
2014-04-11 David Blaikie <dblaikie@gmail.com>
* gdb.opt/inline-break.exp: Explicitly specify -std=gnu89 to
};
Base *base = new Derived ();
+Derived derived;
+Base &base_ref = derived;
void ptr_ref(int*& rptr_int)
{
# Likewise.
gdb_test "gu (print (value-dynamic-type (parse-and-eval \"base\")))" \
"= Derived \[*\]"
+ gdb_test "gu (print (value-dynamic-type (parse-and-eval \"base_ref\")))" \
+ "= Derived \[&\]"
# A static type case.
gdb_test "gu (print (value-dynamic-type (parse-and-eval \"5\")))" \
"= int"