langtools/test/tools/javac/tree/SourceTreeScannerTest.java
changeset 6601 90c4a1a64217
parent 6597 9367c22c445f
child 17578 46ac954e4a84
--- a/langtools/test/tools/javac/tree/SourceTreeScannerTest.java	Thu Sep 16 09:56:25 2010 -0700
+++ b/langtools/test/tools/javac/tree/SourceTreeScannerTest.java	Thu Sep 16 09:57:37 2010 -0700
@@ -91,12 +91,13 @@
             scan(tree, null);
             expect = new HashSet<Tree>();
             reflectiveScan(tree);
+
             if (found.equals(expect)) {
-                System.err.println(found.size() + " trees compared OK");
+                //System.err.println(sourcefile.getName() + ": trees compared OK");
                 return found.size();
             }
 
-            error("Differences found for " + tree.sourcefile.getName());
+            error(sourcefile.getName() + ": differences found");
 
             if (found.size() != expect.size())
                 error("Size mismatch; found: " + found.size() + ", expected: " + expect.size());
@@ -105,13 +106,13 @@
             missing.addAll(expect);
             missing.removeAll(found);
             for (Tree t: missing)
-                error(tree.sourcefile, t, "missing");
+                error(sourcefile, t, "missing");
 
             Set<Tree> excess = new HashSet<Tree>();
             excess.addAll(found);
             excess.removeAll(expect);
             for (Tree t: excess)
-                error(tree.sourcefile, t, "unexpected");
+                error(sourcefile, t, "unexpected");
 
             return 0;
         }
@@ -121,7 +122,7 @@
         public Void scan(Tree tree, Void ignore) {
             if (tree == null)
                 return null;
-            System.err.println("FOUND: " + tree.getKind() + " " + trim(tree, 64));
+            //System.err.println("FOUND: " + tree.getKind() + " " + trim(tree, 64));
             found.add(tree);
             return super.scan(tree, ignore);
         }
@@ -132,7 +133,7 @@
                 return;
             if (o instanceof JCTree) {
                 JCTree tree = (JCTree) o;
-                System.err.println("EXPECT: " + tree.getKind() + " " + trim(tree, 64));
+                //System.err.println("EXPECT: " + tree.getKind() + " " + trim(tree, 64));
                 expect.add(tree);
                 for (Field f: getFields(tree)) {
                     if (TypeBoundKind.class.isAssignableFrom(f.getType())) {