OSDN Git Service

* ax-general.c (gen_traced_pop, gen_int_literal)
authorJim Blandy <jimb@codesourcery.com>
Fri, 26 Oct 2007 23:04:57 +0000 (23:04 +0000)
committerJim Blandy <jimb@codesourcery.com>
Fri, 26 Oct 2007 23:04:57 +0000 (23:04 +0000)
(gen_usual_arithmetic): Check for typedefs.

gdb/ChangeLog
gdb/ax-gdb.c

index 03af1e0..2269549 100644 (file)
@@ -1,3 +1,8 @@
+2007-10-26  Jim Blandy  <jimb@codesourcery.com>
+
+       * ax-general.c (gen_traced_pop, gen_int_literal)
+       (gen_usual_arithmetic): Check for typedefs.
+
 2007-10-26  Joel Brobecker  <brobecker@adacore.com>
 
        * parse.c (prefixify_expression): Minor reformatting.
index 18b7e31..27cc5b1 100644 (file)
@@ -319,7 +319,7 @@ gen_traced_pop (struct agent_expr *ax, struct axs_value *value)
 
       case axs_lvalue_memory:
        {
-         int length = TYPE_LENGTH (value->type);
+         int length = TYPE_LENGTH (check_typedef (value->type));
 
          /* There's no point in trying to use a trace_quick bytecode
             here, since "trace_quick SIZE pop" is three bytes, whereas
@@ -650,7 +650,7 @@ gen_int_literal (struct agent_expr *ax, struct axs_value *value, LONGEST k,
 {
   ax_const_l (ax, k);
   value->kind = axs_rvalue;
-  value->type = type;
+  value->type = check_typedef (type);
 }
 \f
 
@@ -854,7 +854,7 @@ gen_usual_arithmetic (struct agent_expr *ax, struct axs_value *value1,
          ax_simple (ax, aop_swap);
        }
 
-      value1->type = value2->type = target;
+      value1->type = value2->type = check_typedef (target);
     }
 }