* values.c (value_primitive_field): If we're extracting a base
authorJim Blandy <jimb@codesourcery.com>
Mon, 21 May 2001 20:08:59 +0000 (20:08 +0000)
committerJim Blandy <jimb@codesourcery.com>
Mon, 21 May 2001 20:08:59 +0000 (20:08 +0000)
class, then the type of the result should be the base class being
extracted, not the type of which it is a base class.

gdb/ChangeLog
gdb/values.c

index 202bb42514d88004d9cbbb1da1ab726454359007..b154976f864ddfed4ced9ba58021cf7c4fa4606f 100644 (file)
@@ -1,5 +1,9 @@
 2001-05-21  Jim Blandy  <jimb@redhat.com>
 
+       * values.c (value_primitive_field): If we're extracting a base
+       class, then the type of the result should be the base class being
+       extracted, not the type of which it is a base class.
+
        * value.h (struct value): Doc fix, and rearrange members to place
        them near their explanations.
 
index 8336233dab0c6bebeb6e9f8f97c5c489c46138d4..f5a7ce001e17f07e954516928916d7d37f55a342 100644 (file)
@@ -856,7 +856,7 @@ value_primitive_field (register value_ptr arg1, int offset,
          entire object's contents for later references to virtual
          bases, etc.  */
       v = allocate_value (VALUE_ENCLOSING_TYPE (arg1));
-      VALUE_TYPE (v) = arg_type;
+      VALUE_TYPE (v) = type;
       if (VALUE_LAZY (arg1))
        VALUE_LAZY (v) = 1;
       else
This page took 0.027613 seconds and 4 git commands to generate.