langtools/test/tools/javac/annotations/neg/Constant.java
author sogoel
Thu, 28 Aug 2014 23:42:16 -0700
changeset 26273 2663ad455e00
parent 7681 1f0819a3341f
permissions -rw-r--r--
8049126: golden files for annotations test in tools/java dir Reviewed-by: jjg
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
10
06bc494ca11e Initial load
duke
parents:
diff changeset
     1
/*
26273
2663ad455e00 8049126: golden files for annotations test in tools/java dir
sogoel
parents: 7681
diff changeset
     2
 * @test /nodynamiccopyright/
10
06bc494ca11e Initial load
duke
parents:
diff changeset
     3
 * @bug 4901268
06bc494ca11e Initial load
duke
parents:
diff changeset
     4
 * @summary JSR175 (5): annotations must be "constants"
06bc494ca11e Initial load
duke
parents:
diff changeset
     5
 * @author gafter
06bc494ca11e Initial load
duke
parents:
diff changeset
     6
 *
26273
2663ad455e00 8049126: golden files for annotations test in tools/java dir
sogoel
parents: 7681
diff changeset
     7
 * @compile/fail/ref=Constant.out -XDrawDiagnostics  Constant.java
10
06bc494ca11e Initial load
duke
parents:
diff changeset
     8
 */
06bc494ca11e Initial load
duke
parents:
diff changeset
     9
5011
428dd17fdb26 6931127: strange test class files
jjg
parents: 2985
diff changeset
    10
package Constant;
10
06bc494ca11e Initial load
duke
parents:
diff changeset
    11
06bc494ca11e Initial load
duke
parents:
diff changeset
    12
@T(a = X.x)
06bc494ca11e Initial load
duke
parents:
diff changeset
    13
@interface T {
06bc494ca11e Initial load
duke
parents:
diff changeset
    14
    int a();
06bc494ca11e Initial load
duke
parents:
diff changeset
    15
}
06bc494ca11e Initial load
duke
parents:
diff changeset
    16
06bc494ca11e Initial load
duke
parents:
diff changeset
    17
class X {
06bc494ca11e Initial load
duke
parents:
diff changeset
    18
    static int x;
06bc494ca11e Initial load
duke
parents:
diff changeset
    19
}