equal
deleted
inserted
replaced
986 // Use one stack to keep both: child's node/state and parent's node/index |
986 // Use one stack to keep both: child's node/state and parent's node/index |
987 MStack mstack(max_stack * 2 * 2); // C->unique() * 2 * 2 |
987 MStack mstack(max_stack * 2 * 2); // C->unique() * 2 * 2 |
988 mstack.push(n, Visit, NULL, -1); // set NULL as parent to indicate root |
988 mstack.push(n, Visit, NULL, -1); // set NULL as parent to indicate root |
989 |
989 |
990 while (mstack.is_nonempty()) { |
990 while (mstack.is_nonempty()) { |
|
991 C->check_node_count(NodeLimitFudgeFactor, "too many nodes matching instructions"); |
|
992 if (C->failing()) return NULL; |
991 n = mstack.node(); // Leave node on stack |
993 n = mstack.node(); // Leave node on stack |
992 Node_State nstate = mstack.state(); |
994 Node_State nstate = mstack.state(); |
993 if (nstate == Visit) { |
995 if (nstate == Visit) { |
994 mstack.set_state(Post_Visit); |
996 mstack.set_state(Post_Visit); |
995 Node *oldn = n; |
997 Node *oldn = n; |