From: Kimon Hoffmann Date: Mon, 27 Jun 2005 15:46:06 +0000 (+0000) Subject: Fixed small copy & paste error in the "foreach" defines and added additional defines... X-Git-Url: http://nsz.repo.hu/git/?a=commitdiff_plain;h=ea1fc4bc4471f4e92e8df1f5f62da9aa3b1685e7;p=libfirm Fixed small copy & paste error in the "foreach" defines and added additional defines for node and edge iteration. --- diff --git a/ir/be/beifg.h b/ir/be/beifg.h index 182ed7969..ec0c9c6d0 100644 --- a/ir/be/beifg.h +++ b/ir/be/beifg.h @@ -74,6 +74,13 @@ int be_ifg_has_edge(const be_if_graph_t* graph, const be_if_node_t* n1, const be pset_count(ifnode->neighb) #define be_ifn_foreach_neighbour(ifnode, curr) \ - for (curr = pset_first(ifnode->neighb); curr; curr = pset_next(ifnode->neighb)) + for (curr = pset_first(ifnode->neighbourNodes); curr; curr = pset_next(ifnode->neighbourNodes)) + +#define be_ifg_foreach_node(ifgraph, curr) \ + for (curr = set_first(ifgraph->nodes); curr; curr = set_next(ifgraph->nodes)) + +#define be_ifg_foreach_edge(ifgraph, curr) \ + for (curr = set_first(ifgraph->edges); curr; curr = set_next(ifgraph->edges)) + #endif /*_BEIFG_H_*/