test/tools/javac/processing/model/element/TestAnonClassNames.java

Print this page

        

*** 24,33 **** --- 24,35 ---- /* * @test * @bug 6449781 * @summary Test that reported names of anonymous classes are non-null. * @author Joseph D. Darcy + * @library ../../../lib + * @build JavacTestingAbstractProcessor * @build TestAnonSourceNames * @compile -processor TestAnonSourceNames TestAnonClassNames.java * @run main TestAnonClassNames */
*** 139,150 **** } /** * Probe at the various kinds of names of a type element. */ ! @SupportedAnnotationTypes("*") ! class ClassNameProber extends AbstractProcessor { public ClassNameProber(){super();} private boolean classesFound=false; public boolean process(Set<? extends TypeElement> annotations, --- 141,151 ---- } /** * Probe at the various kinds of names of a type element. */ ! class ClassNameProber extends JavacTestingAbstractProcessor { public ClassNameProber(){super();} private boolean classesFound=false; public boolean process(Set<? extends TypeElement> annotations,
*** 172,181 **** if (!classesFound) { throw new RuntimeException("Error: no classes processed."); } return true; } - - public SourceVersion getSupportedSourceVersion() { - return SourceVersion.latest(); - } } --- 173,178 ----