Lot's of work on a CGenerator, AST and language improvements

This commit is contained in:
Nathan Braswell
2013-11-01 02:52:18 -04:00
parent ededb069c1
commit 77f2b0a3e5
14 changed files with 232 additions and 28 deletions

View File

@@ -41,10 +41,8 @@ NodeTree<T>* CollapseTransformation<T>::transform(NodeTree<T>* from) {
if (children[i]->getData() == toCollapse) {
node->removeChild(children[i]);
std::vector<NodeTree<T>*> newChildren = children[i]->getChildren();
node->addChildren(newChildren);
node->insertChildren(i,newChildren);
toProcess.push(node); //Do this node again
// for (int j = 0; j < newChildren.size(); j++)
// toProcess.push(newChildren[j]);
}
else
toProcess.push(children[i]);