lots'o'fixes in the output routines; still a looong way to go.

This commit is contained in:
Mihai Bazon
2012-08-16 19:54:37 +03:00
parent 7f273c3b89
commit c7c163b82e
4 changed files with 161 additions and 78 deletions

View File

@@ -23,6 +23,10 @@
var ast = parse(fs.readFileSync(filename, "utf8"));
console.timeEnd("parse");
var stream = OutputStream({ beautify: true });
ast.print(stream);
console.log(stream.get());
// console.time("walk");
// var w = new TreeWalker(function(node){
// console.log(node.TYPE + " [ start: " + node.start.line + ":" + node.start.col + ", end: " + node.end.line + ":" + node.end.col + "] " + node.name);