dwarf2out.c (loc_descriptor_from_tree): Add TRUTH_*_EXPR cases.
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>
Sun, 20 Jan 2002 23:46:30 +0000 (23:46 +0000)
committerRichard Kenner <kenner@gcc.gnu.org>
Sun, 20 Jan 2002 23:46:30 +0000 (18:46 -0500)
* dwarf2out.c (loc_descriptor_from_tree): Add TRUTH_*_EXPR cases.
(gen_struct_or_union_type_die): Don't SIGSEGV if no TYPE_STUB_DECL
in incomplete case.

From-SVN: r49022

gcc/ChangeLog
gcc/dwarf2out.c

index 9a56b8105d48125e6f1b706f8d07af76f65c6d59..ce2700050ac51d926f8714e279acfb87a255d369 100644 (file)
@@ -1,3 +1,9 @@
+Sun Jan 20 18:40:14 2002  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
+
+       * dwarf2out.c (loc_descriptor_from_tree): Add TRUTH_*_EXPR cases.
+       (gen_struct_or_union_type_die): Don't SIGSEGV if no TYPE_STUB_DECL
+       in incomplete case.
+
 2002-01-20  Graham Stott  <grahams@redhat.com>
 
        * cfgloop.c (flow_loop_preheader_scan): Fix typo.
index a5073214e1d05e565001405937de670cfc2d9f24..c0b9958b2c727b84c9ced4d907dc0a144e05dc42 100644 (file)
@@ -8066,14 +8066,19 @@ loc_descriptor_from_tree (loc, addressp)
        return 0;
       break;
 
+    case TRUTH_AND_EXPR: 
+    case TRUTH_ANDIF_EXPR:
     case BIT_AND_EXPR:
       op = DW_OP_and;
       goto do_binop;
 
+    case TRUTH_XOR_EXPR:
     case BIT_XOR_EXPR:
       op = DW_OP_xor;
       goto do_binop;
 
+    case TRUTH_OR_EXPR:
+    case TRUTH_ORIF_EXPR:
     case BIT_IOR_EXPR:
       op = DW_OP_or;
       goto do_binop;
@@ -8167,6 +8172,7 @@ loc_descriptor_from_tree (loc, addressp)
       add_loc_descr (&ret, new_loc_descr (op, 0, 0));
       break;
 
+    case TRUTH_NOT_EXPR:
     case BIT_NOT_EXPR:
       op = DW_OP_not;
       goto do_unop;
@@ -10829,7 +10835,8 @@ gen_struct_or_union_type_die (type, context_die)
       add_AT_flag (type_die, DW_AT_declaration, 1);
 
       /* We don't need to do this for function-local types.  */
-      if (! decl_function_context (TYPE_STUB_DECL (type)))
+      if (TYPE_STUB_DECL (type)
+         && ! decl_function_context (TYPE_STUB_DECL (type)))
        VARRAY_PUSH_TREE (incomplete_types, type);
     }
 }