bugfix
authorGötz Lindenmaier <goetz@ipd.info.uni-karlsruhe.de>
Wed, 30 Jul 2003 13:49:24 +0000 (13:49 +0000)
committerGötz Lindenmaier <goetz@ipd.info.uni-karlsruhe.de>
Wed, 30 Jul 2003 13:49:24 +0000 (13:49 +0000)
[r1585]

ir/tr/entity.c

index 7abe7cf..8391547 100644 (file)
@@ -475,15 +475,16 @@ is_compound_graph_path(void *thing) {
 /* checks whether nodes 0..pos are correct (all lie on a path.) */
 /* @@@ not implemented */
 INLINE int is_proper_compound_graph_path(compound_graph_path *gr, int pos) {
+  int i;
   entity *node;
   type *owner = gr->tp;
   for (i = 0; i <= pos; i++) {
     node = get_compound_graph_path_node(gr, i);
     if (get_entity_owner(node) != owner) return false;
-    type = get_entity_type(node);
+    owner = get_entity_type(node);
   }
   if (pos == get_compound_graph_path_length(gr) -1)
-    if (!is_atomic_type(type)) return false;
+    if (!is_atomic_type(owner)) return false;
   return true;
 }