8193191: Update JavacTestingAbstractProcessor for JDK 10
Reviewed-by: jjg
This commit is contained in:
parent
9f07305ab6
commit
62d672208a
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2010, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -31,13 +31,7 @@ import static javax.lang.model.SourceVersion.*;
|
||||
* An abstract annotation processor tailored to {@code javac} regression testing.
|
||||
*/
|
||||
public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
private static final Set<String> allAnnotations;
|
||||
|
||||
static {
|
||||
Set<String> tmp = new HashSet<>();
|
||||
tmp.add("*");
|
||||
allAnnotations = Collections.unmodifiableSet(tmp);
|
||||
}
|
||||
private static final Set<String> allAnnotations = Set.of("*");
|
||||
|
||||
protected Elements eltUtils;
|
||||
protected Elements elements;
|
||||
@ -116,7 +110,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
* corresponding platform visitor type.
|
||||
*/
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static abstract class AbstractAnnotationValueVisitor<R, P> extends AbstractAnnotationValueVisitor9<R, P> {
|
||||
|
||||
/**
|
||||
@ -127,7 +121,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static abstract class AbstractElementVisitor<R, P> extends AbstractElementVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses to call.
|
||||
@ -137,7 +131,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static abstract class AbstractTypeVisitor<R, P> extends AbstractTypeVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses to call.
|
||||
@ -147,7 +141,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class ElementKindVisitor<R, P> extends ElementKindVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses; uses {@code null} for the
|
||||
@ -168,7 +162,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class ElementScanner<R, P> extends ElementScanner9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses; uses {@code null} for the
|
||||
@ -187,7 +181,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class SimpleAnnotationValueVisitor<R, P> extends SimpleAnnotationValueVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses; uses {@code null} for the
|
||||
@ -208,7 +202,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class SimpleElementVisitor<R, P> extends SimpleElementVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses; uses {@code null} for the
|
||||
@ -229,7 +223,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class SimpleTypeVisitor<R, P> extends SimpleTypeVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses; uses {@code null} for the
|
||||
@ -250,7 +244,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor {
|
||||
}
|
||||
}
|
||||
|
||||
@SupportedSourceVersion(RELEASE_9)
|
||||
@SupportedSourceVersion(RELEASE_10)
|
||||
public static class TypeKindVisitor<R, P> extends TypeKindVisitor9<R, P> {
|
||||
/**
|
||||
* Constructor for concrete subclasses to call; uses {@code null}
|
||||
|
Loading…
Reference in New Issue
Block a user