test/tools/javac/annotations/typeAnnotations/classfile/ClassfileTestHelper.java

changeset 2134
b0c086cd4520
parent 1755
ddb4a2bfcd82
child 2525
2eb010b6cb22
     1.1 --- a/test/tools/javac/annotations/typeAnnotations/classfile/ClassfileTestHelper.java	Tue Oct 15 22:15:35 2013 +0200
     1.2 +++ b/test/tools/javac/annotations/typeAnnotations/classfile/ClassfileTestHelper.java	Tue Oct 15 15:57:13 2013 -0700
     1.3 @@ -36,7 +36,8 @@
     1.4  
     1.5      //Makes debugging much easier. Set to 'false' for less output.
     1.6      public Boolean verbose = true;
     1.7 -    void println(String msg) { if(verbose) System.out.println(msg); }
     1.8 +    void println(String msg) { if (verbose) System.out.println(msg); }
     1.9 +    void print(String msg) { if (verbose) System.out.print(msg); }
    1.10  
    1.11      File writeTestFile(String fname, String source) throws IOException {
    1.12        File f = new File(fname);
    1.13 @@ -183,6 +184,13 @@
    1.14                          (RuntimeTypeAnnotations_attribute)attr;
    1.15                  println(testtype + ": " + name + ", " + annName + ": " +
    1.16                          tAttr.annotations.length );
    1.17 +                if (tAttr.annotations.length > 0) {
    1.18 +                    for (int i = 0; i < tAttr.annotations.length; i++) {
    1.19 +                        println("  types:" + tAttr.annotations[i].position.type);
    1.20 +                    }
    1.21 +                } else {
    1.22 +                    println("");
    1.23 +                }
    1.24                  allt += tAttr.annotations.length;
    1.25                  if (visible)
    1.26                      tvisibles += tAttr.annotations.length;

mercurial