* - execute the pre function before recursion
* - execute the post function after recursion
*/
-#ifdef HAVE_CONFIG_H
-# include "config.h"
-#endif
-
-#ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
+#include "config.h"
+#include <stdlib.h>
#include <stdio.h>
#include "entity_t.h"
/* execute post method */
if (post)
post(tore, env);
-
- return;
}
/** Check whether node contains types or entities as an attribute.
do_type_walk(cont, pre, post, env);
}
+void type_walk_plus_frames(type_walk_func *pre, type_walk_func *post, void *env) {
+ int i, n_irgs = get_irp_n_irgs();
+ type_or_ent cont;
+
+ type_walk(pre, post, env);
+
+ for (i = 0; i < n_irgs; ++i) {
+ ir_graph *irg = get_irp_irg(i);
+ cont.typ = get_irg_frame_type(irg);
+ do_type_walk(cont, pre, post, env);
+
+ cont.typ = get_method_value_param_type(get_entity_type(get_irg_entity(irg)));
+ if(cont.typ)
+ do_type_walk(cont, pre, post, env);
+ }
+}
+
void type_walk_irg(ir_graph *irg,
type_walk_func *pre,
type_walk_func *post,
do_type_walk(cont, pre, post, env);
current_ir_graph = rem;
- return;
}
static void type_walk_s2s_2(type_or_ent tore,
printf(" *** Faulty type or entity! \n");
break;
}
- return;
}
void type_walk_super2sub(type_walk_func *pre,
printf(" *** Faulty type or entity! \n");
break;
}
- return;
}
void type_walk_super(type_walk_func *pre,
/* execute post method */
if (post)
post(tp, env);
-
- return;
}
void class_walk_super2sub(class_walk_func *pre,