diff --git a/core/src/main/java/fr/labri/gumtree/io/TreeGenerator.java b/core/src/main/java/fr/labri/gumtree/io/TreeGenerator.java
index <HASH>..<HASH> 100644
--- a/core/src/main/java/fr/labri/gumtree/io/TreeGenerator.java
+++ b/core/src/main/java/fr/labri/gumtree/io/TreeGenerator.java
@@ -16,9 +16,7 @@ public abstract class TreeGenerator {
 	
 	public TreeContext generateFromReader(Reader r) throws IOException {
 		TreeContext ctx = generate(r);
-		ITree root = ctx.getRoot();
-		root.refresh();
-		TreeUtils.postOrderNumbering(root);
+		ctx.validate();
 		return ctx;
 	}
TreeGenerator now uses the validate method of TreeContext.