|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.sun.tools.javac.comp.Check
public class Check
Type checking helper class for the attribution phase.
This is NOT part of any API supported by Sun Microsystems. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
| Nested Class Summary | |
|---|---|
private class |
Check.ConversionWarner
|
(package private) class |
Check.Validator
A visitor class for type validation. |
| Field Summary | |
|---|---|
(package private) boolean |
allowAnnotations
Switch: annotations enabled? |
(package private) boolean |
allowGenerics
Switch: generics enabled? |
protected static Context.Key<Check> |
checkKey
|
java.util.Map<Name,Symbol.ClassSymbol> |
compiled
A table mapping flat names of all compiled classes in this run to their symbols; maintained from outside. |
(package private) boolean |
complexInference
Switch: -complexinference option set? |
private MandatoryWarningHandler |
deprecationHandler
A handler for messages about deprecated usage. |
private JCDiagnostic.Factory |
diags
|
private Infer |
infer
|
private Lint |
lint
|
private Log |
log
|
private Names |
names
|
(package private) Warner |
overrideWarner
|
private boolean |
skipAnnotations
|
private Source |
source
|
private Symtab |
syms
|
private Target |
target
|
private TreeInfo |
treeinfo
|
private Types |
types
|
private MandatoryWarningHandler |
uncheckedHandler
A handler for messages about unchecked or unsafe usage. |
private Check.Validator |
validator
Validate a type expression. |
| Constructor Summary | |
|---|---|
protected |
Check(Context context)
|
| Method Summary | |
|---|---|
(package private) boolean |
annotationApplicable(JCTree.JCAnnotation a,
Symbol s)
Is the annotation applicable to the symbol? |
(package private) java.lang.Object |
cannotOverride(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
A customized "cannot override" error message. |
Warner |
castWarner(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type expected)
|
(package private) void |
checkAllDefined(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c)
Check that all abstract members of given class have definitions. |
(package private) void |
checkAnnotationResType(JCDiagnostic.DiagnosticPosition pos,
Type type)
|
void |
checkCanonical(JCTree tree)
Check that a qualified name is in canonical form (for import decls). |
private void |
checkCapture(JCTree.JCTypeApply tree)
Check that a type is within some bounds. |
(package private) Type |
checkCastable(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type req)
Check that a given type can be cast to a given target type. |
(package private) void |
checkClassBounds(JCDiagnostic.DiagnosticPosition pos,
java.util.Map<Symbol.TypeSymbol,Type> seensofar,
Type type)
Enter all interfaces of type `type' into the hash table `seensofar' with their class symbol as key and their type as value. |
(package private) void |
checkClassBounds(JCDiagnostic.DiagnosticPosition pos,
Type type)
Check that class c does not implement directly or indirectly the same parameterized interface with two different argument lists. |
(package private) Type |
checkClassType(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check that type is a class or interface type. |
(package private) Type |
checkClassType(JCDiagnostic.DiagnosticPosition pos,
Type t,
boolean noBounds)
Check that type is a class or interface type. |
(package private) boolean |
checkCommonOverriderIn(Symbol s1,
Symbol s2,
Type site)
|
boolean |
checkCompatibleAbstracts(JCDiagnostic.DiagnosticPosition pos,
Type t1,
Type t2)
Check that classes (or interfaces) do not each define an abstract method with same name and arguments but incompatible return types. |
boolean |
checkCompatibleAbstracts(JCDiagnostic.DiagnosticPosition pos,
Type t1,
Type t2,
Type site)
|
void |
checkCompatibleConcretes(JCDiagnostic.DiagnosticPosition pos,
Type site)
Check that a class does not inherit two concrete methods with the same signature. |
(package private) void |
checkCompatibleSupertypes(JCDiagnostic.DiagnosticPosition pos,
Type c)
Check that all abstract methods implemented by a class are mutually compatible. |
private void |
checkCyclicConstructor(JCTree.JCClassDecl tree,
Symbol ctor,
java.util.Map<Symbol,Symbol> callMap)
Look in the map to see if the given constructor is part of a call cycle. |
(package private) void |
checkCyclicConstructors(JCTree.JCClassDecl tree)
Check for cycles in the graph of constructors calling other constructors. |
(package private) void |
checkDeprecatedAnnotation(JCDiagnostic.DiagnosticPosition pos,
Symbol s)
|
(package private) boolean |
checkDisjoint(JCDiagnostic.DiagnosticPosition pos,
long flags,
long set1,
long set2)
Check that flag set does not contain elements of two conflicting sets. |
(package private) void |
checkDivZero(JCDiagnostic.DiagnosticPosition pos,
Symbol operator,
Type operand)
Check for division by integer constant zero |
(package private) void |
checkEmptyIf(JCTree.JCIf tree)
Check for empty statements after if |
private void |
checkExtends(JCDiagnostic.DiagnosticPosition pos,
Type a,
Type.TypeVar bs)
Check that a type is within some bounds. |
(package private) long |
checkFlags(JCDiagnostic.DiagnosticPosition pos,
long flags,
Symbol sym,
JCTree tree)
Check that given modifiers are legal for given symbol and return modifiers together with any implicit modififiers for that symbol. |
(package private) void |
checkImplementations(JCTree.JCClassDecl tree)
Check that all methods which implement some method conform to the method they implement. |
(package private) void |
checkImplementations(JCTree.JCClassDecl tree,
Symbol.ClassSymbol ic)
Check that all methods which implement some method in `ic' conform to the method they implement. |
(package private) void |
checkNonCyclic(JCDiagnostic.DiagnosticPosition pos,
Type.TypeVar t)
|
(package private) void |
checkNonCyclic(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check for cyclic references. |
private void |
checkNonCyclic1(JCDiagnostic.DiagnosticPosition pos,
Type t,
java.util.Set<Type.TypeVar> seen)
|
(package private) void |
checkNonCyclicElements(JCTree.JCClassDecl tree)
Check for cycles in the graph of annotation elements. |
(package private) void |
checkNonCyclicElementsInternal(JCDiagnostic.DiagnosticPosition pos,
Symbol.TypeSymbol tsym)
|
private boolean |
checkNonCyclicInternal(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check for cyclic references. |
(package private) Type |
checkNonVoid(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check that type is different from 'void'. |
(package private) void |
checkNotRepeated(JCDiagnostic.DiagnosticPosition pos,
Type it,
java.util.Set<Type> its)
Enter interface into into set. |
(package private) Type |
checkNullOrRefType(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check that type is a null or reference type. |
(package private) int |
checkOperator(JCDiagnostic.DiagnosticPosition pos,
Symbol.OperatorSymbol operator,
int tag,
Type left,
Type right)
Return the opcode of the operator but emit an error if it is an error. |
(package private) void |
checkOverride(JCTree tree,
Symbol.MethodSymbol m)
Check that a given method conforms with any method it overrides. |
(package private) void |
checkOverride(JCTree tree,
Symbol.MethodSymbol m,
Symbol.MethodSymbol other,
Symbol.ClassSymbol origin)
Check that this method conforms with overridden method 'other'. |
(package private) void |
checkRaw(JCTree tree,
Env<AttrContext> env)
|
(package private) Type |
checkRefType(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check that type is a reference type, i.e. |
(package private) Type |
checkReifiableReferenceType(JCDiagnostic.DiagnosticPosition pos,
Type t)
Check that type is a reifiable class, interface or array type. |
(package private) void |
checkTransparentClass(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c,
Scope s)
Check that a class or interface does not hide a class or interface with same name in immediately enclosing local scope. |
(package private) void |
checkTransparentVar(JCDiagnostic.DiagnosticPosition pos,
Symbol.VarSymbol v,
Scope s)
Check that variable does not hide variable with same name in immediately enclosing local scope. |
(package private) Type |
checkType(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type req)
Check that a given type is assignable to a given proto-type. |
(package private) boolean |
checkUnique(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
Check that symbol is unique in given scope. |
(package private) boolean |
checkUniqueClassName(JCDiagnostic.DiagnosticPosition pos,
Name name,
Scope s)
Check that class does not have the same name as one of its enclosing classes, or as a class defined in its enclosing scope. |
(package private) boolean |
checkUniqueImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
Check that single-type import is not already imported or top-level defined, but make an exception for two single-type imports which denote the same type. |
private boolean |
checkUniqueImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s,
boolean staticImport)
Check that single-type import is not already imported or top-level defined, but make an exception for two single-type imports which denote the same type. |
(package private) boolean |
checkUniqueStaticImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
Check that static single-type import is not already imported or top-level defined, but make an exception for two single-type imports which denote the same type. |
private void |
closure(Type t,
java.util.Map<Symbol.TypeSymbol,Type> typeMap)
Compute all the supertypes of t, indexed by type symbol. |
private void |
closure(Type t,
java.util.Map<Symbol.TypeSymbol,Type> typesSkip,
java.util.Map<Symbol.TypeSymbol,Type> typeMap)
Compute all the supertypes of t, indexed by type symbol (except thise in typesSkip). |
Type |
completionError(JCDiagnostic.DiagnosticPosition pos,
Symbol.CompletionFailure ex)
Report a failure to complete a class. |
Warner |
convertWarner(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type expected)
|
(package private) List<Type> |
diff(List<Type> ts1,
List<Type> ts2)
Form the difference of two type lists. |
(package private) void |
duplicateError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
Report duplicate declaration error. |
(package private) void |
earlyRefError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
Report an error that symbol cannot be referenced before super has been called. |
(package private) List<Type> |
excl(Type t,
List<Type> ts)
Remove type set from type set list. |
private Symbol |
firstDirectIncompatibility(Type t1,
Type t2,
Type site)
Return the first method in t2 that conflicts with a method from t1. |
private Symbol |
firstIncompatibility(Type t1,
Type t2,
Type site)
Return the first method which is defined with same args but different return types in two given interfaces, or null if none exists. |
private Symbol.MethodSymbol |
firstUndef(Symbol.ClassSymbol impl,
Symbol.ClassSymbol c)
Return first abstract member of class `c' that is not defined in `impl', null if there is none. |
private long |
implicitEnumFinalFlag(JCTree tree)
Determine if this enum should be implicitly final. |
(package private) List<Type> |
incl(Type t,
List<Type> ts)
Add type set to given type list, unless it is a subclass of some class in the list. |
static Check |
instance(Context context)
|
(package private) Type |
instantiatePoly(JCDiagnostic.DiagnosticPosition pos,
Type.ForAll t,
Type pt,
Warner warn)
Instantiate polymorphic type to some prototype, unless prototype is `anyPoly' in which case polymorphic type is returned unchanged. |
List<Type> |
intersect(List<Type> ts1,
List<Type> ts2)
Form the intersection of two type lists. |
(package private) boolean |
intersects(Type t,
List<Type> ts)
Is given type a subtype or supertype of some of the types in given list? |
private boolean |
isCanonical(JCTree tree)
|
private boolean |
isDeprecatedOverrideIgnorable(Symbol.MethodSymbol m,
Symbol.ClassSymbol origin)
|
(package private) boolean |
isHandled(Type exc,
List<Type> handled)
Is exc handled by given exception list? |
(package private) boolean |
isOverrider(Symbol s)
Is s a method symbol that overrides a method in a superclass? |
(package private) boolean |
isTypeVar(Type t)
Is type a type variable, or a (possibly multi-dimensional) array of type variables? |
(package private) boolean |
isUnchecked(JCDiagnostic.DiagnosticPosition pos,
Type exc)
Same, but handling completion failures. |
(package private) boolean |
isUnchecked(Symbol.ClassSymbol exc)
Is exc an exception symbol that need not be declared? |
(package private) boolean |
isUnchecked(Type exc)
Is exc an exception type that need not be declared? |
(package private) Name |
localClassName(Symbol.ClassSymbol c)
Return name of local class. |
private void |
noteCyclic(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c)
Note that we found an inheritance cycle. |
(package private) static int |
protection(long flags)
The level of access protection given by a flag set, where PRIVATE is highest and PUBLIC is lowest. |
void |
reportDeferredDiagnostics()
Report any deferred diagnostics. |
(package private) Lint |
setLint(Lint newLint)
|
(package private) boolean |
subset(Type t,
List<Type> ts)
Is given type a subtype of some of the types in given list? |
(package private) Type |
typeError(JCDiagnostic.DiagnosticPosition pos,
java.lang.Object problem,
Type found,
Type req)
Report a type error. |
(package private) Type |
typeError(JCDiagnostic.DiagnosticPosition pos,
java.lang.String problem,
Type found,
Type req,
java.lang.Object explanation)
|
(package private) Type |
typeTagError(JCDiagnostic.DiagnosticPosition pos,
java.lang.Object required,
java.lang.Object found)
Report an error that wrong type tag was found. |
(package private) java.lang.Object |
uncheckedOverrides(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
A customized "override" warning message. |
(package private) List<Type> |
unHandled(List<Type> thrown,
List<Type> handled)
Return all exceptions in thrown list that are not in handled list. |
(package private) List<Type> |
union(List<Type> ts1,
List<Type> ts2)
Form the union of two type set lists. |
(package private) void |
validate(JCTree tree,
Env<AttrContext> env)
Visitor method: Validate a type expression, if it is not null, catching and reporting any completion failures. |
(package private) void |
validate(List<? extends JCTree> trees,
Env<AttrContext> env)
Visitor method: Validate a list of type expressions. |
void |
validateAnnotation(JCTree.JCAnnotation a)
Check an annotation value. |
void |
validateAnnotation(JCTree.JCAnnotation a,
Symbol s)
Check an annotation of a symbol. |
(package private) void |
validateAnnotationMethod(JCDiagnostic.DiagnosticPosition pos,
Symbol.MethodSymbol m)
"It is also a compile-time error if any method declared in an annotation type has a signature that is override-equivalent to that of any public or protected method declared in class Object or in the interface annotation.Annotation." |
void |
validateAnnotations(List<JCTree.JCAnnotation> annotations,
Symbol s)
Check the annotations of a symbol. |
(package private) void |
validateAnnotationType(JCDiagnostic.DiagnosticPosition pos,
Type type)
|
(package private) void |
validateAnnotationType(JCTree restype)
Annotation types are restricted to primitives, String, an enum, an annotation, Class, Class>, Class extends Anything>, arrays of the preceding. |
(package private) void |
varargsDuplicateError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym1,
Symbol sym2)
Report array/varargs duplicate declaration |
(package private) java.lang.Object |
varargsOverrides(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
A customized "override" warning message. |
(package private) void |
warnDeprecated(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
Warn about deprecated symbol. |
void |
warnUnchecked(JCDiagnostic.DiagnosticPosition pos,
java.lang.String msg,
java.lang.Object... args)
Warn about unchecked operation. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final Context.Key<Check> checkKey
private final Names names
private final Log log
private final Symtab syms
private final Infer infer
private final Target target
private final Source source
private final Types types
private final JCDiagnostic.Factory diags
private final boolean skipAnnotations
private final TreeInfo treeinfo
private Lint lint
boolean allowGenerics
boolean allowAnnotations
boolean complexInference
public java.util.Map<Name,Symbol.ClassSymbol> compiled
private MandatoryWarningHandler deprecationHandler
private MandatoryWarningHandler uncheckedHandler
private Check.Validator validator
Warner overrideWarner
| Constructor Detail |
|---|
protected Check(Context context)
| Method Detail |
|---|
public static Check instance(Context context)
Lint setLint(Lint newLint)
void warnDeprecated(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
pos - Position to be used for error reporting.sym - The deprecated symbol.
public void warnUnchecked(JCDiagnostic.DiagnosticPosition pos,
java.lang.String msg,
java.lang.Object... args)
pos - Position to be used for error reporting.msg - A string describing the problem.public void reportDeferredDiagnostics()
public Type completionError(JCDiagnostic.DiagnosticPosition pos,
Symbol.CompletionFailure ex)
pos - Position to be used for error reporting.ex - The failure to report.
Type typeError(JCDiagnostic.DiagnosticPosition pos,
java.lang.Object problem,
Type found,
Type req)
pos - Position to be used for error reporting.problem - A string describing the error.found - The type that was found.req - The type that was required.
Type typeError(JCDiagnostic.DiagnosticPosition pos,
java.lang.String problem,
Type found,
Type req,
java.lang.Object explanation)
Type typeTagError(JCDiagnostic.DiagnosticPosition pos,
java.lang.Object required,
java.lang.Object found)
pos - Position to be used for error reporting.required - An internationalized string describing the type tag
required.found - The type that was found.
void earlyRefError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
pos - Position to be used for error reporting.sym - The referenced symbol.
void duplicateError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym)
void varargsDuplicateError(JCDiagnostic.DiagnosticPosition pos,
Symbol sym1,
Symbol sym2)
void checkTransparentVar(JCDiagnostic.DiagnosticPosition pos,
Symbol.VarSymbol v,
Scope s)
pos - Position for error reporting.v - The symbol.s - The scope.
void checkTransparentClass(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c,
Scope s)
pos - Position for error reporting.c - The symbol.s - The scope.
boolean checkUniqueClassName(JCDiagnostic.DiagnosticPosition pos,
Name name,
Scope s)
pos - Position for error reporting.name - The class name.s - The enclosing scope.Name localClassName(Symbol.ClassSymbol c)
Type checkType(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type req)
pos - Position to be used for error reporting.found - The type that was found.req - The type that was required.
Type instantiatePoly(JCDiagnostic.DiagnosticPosition pos,
Type.ForAll t,
Type pt,
Warner warn)
Type checkCastable(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type req)
pos - Position to be used for error reporting.found - The type that is being cast.req - The target type of the cast.boolean isTypeVar(Type t)
private void checkExtends(JCDiagnostic.DiagnosticPosition pos,
Type a,
Type.TypeVar bs)
pos - Position to be used for error reporting.a - The type that should be bounded by bs.bs - The bound.private void checkCapture(JCTree.JCTypeApply tree)
pos - Position to be used for error reporting.a - The type that should be bounded by bs.bs - The bound.
Type checkNonVoid(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type to be checked.
Type checkClassType(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type to be checked.
Type checkClassType(JCDiagnostic.DiagnosticPosition pos,
Type t,
boolean noBounds)
pos - Position to be used for error reporting.t - The type to be checked.noBounds - True if type bounds are illegal here.
Type checkReifiableReferenceType(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type to be checked.
Type checkRefType(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type to be checked.
Type checkNullOrRefType(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type to be checked.
boolean checkDisjoint(JCDiagnostic.DiagnosticPosition pos,
long flags,
long set1,
long set2)
pos - Position to be used for error reporting.flags - The set of flags to be checked.set1 - Conflicting flags set #1.set2 - Conflicting flags set #2.
long checkFlags(JCDiagnostic.DiagnosticPosition pos,
long flags,
Symbol sym,
JCTree tree)
pos - Position to be used for error reporting.flags - The set of modifiers given in a definition.sym - The defined symbol.private long implicitEnumFinalFlag(JCTree tree)
void validate(JCTree tree,
Env<AttrContext> env)
void checkRaw(JCTree tree,
Env<AttrContext> env)
void validate(List<? extends JCTree> trees,
Env<AttrContext> env)
boolean subset(Type t,
List<Type> ts)
boolean intersects(Type t,
List<Type> ts)
List<Type> incl(Type t,
List<Type> ts)
List<Type> excl(Type t,
List<Type> ts)
List<Type> union(List<Type> ts1,
List<Type> ts2)
List<Type> diff(List<Type> ts1,
List<Type> ts2)
public List<Type> intersect(List<Type> ts1,
List<Type> ts2)
boolean isUnchecked(Symbol.ClassSymbol exc)
boolean isUnchecked(Type exc)
boolean isUnchecked(JCDiagnostic.DiagnosticPosition pos,
Type exc)
boolean isHandled(Type exc,
List<Type> handled)
List<Type> unHandled(List<Type> thrown,
List<Type> handled)
thrown - The list of thrown exceptions.handled - The list of handled exceptions.static int protection(long flags)
java.lang.Object cannotOverride(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
m - The overriding method.other - The overridden method.
java.lang.Object uncheckedOverrides(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
m - The overriding method.other - The overridden method.
java.lang.Object varargsOverrides(Symbol.MethodSymbol m,
Symbol.MethodSymbol other)
m - The overriding method.other - The overridden method.
void checkOverride(JCTree tree,
Symbol.MethodSymbol m,
Symbol.MethodSymbol other,
Symbol.ClassSymbol origin)
tree - The tree from which positions
are extracted for errors.m - The overriding method.other - The overridden method.origin - The class of which the overriding method
is a member.
private boolean isDeprecatedOverrideIgnorable(Symbol.MethodSymbol m,
Symbol.ClassSymbol origin)
public void checkCompatibleConcretes(JCDiagnostic.DiagnosticPosition pos,
Type site)
pos - Position to be used for error reporting.site - The class type to be checked.
public boolean checkCompatibleAbstracts(JCDiagnostic.DiagnosticPosition pos,
Type t1,
Type t2)
pos - Position to be used for error reporting.t1 - The first argument type.t2 - The second argument type.
public boolean checkCompatibleAbstracts(JCDiagnostic.DiagnosticPosition pos,
Type t1,
Type t2,
Type site)
private Symbol firstIncompatibility(Type t1,
Type t2,
Type site)
t1 - The first type.t2 - The second type.site - The most derived type.
private void closure(Type t,
java.util.Map<Symbol.TypeSymbol,Type> typeMap)
private void closure(Type t,
java.util.Map<Symbol.TypeSymbol,Type> typesSkip,
java.util.Map<Symbol.TypeSymbol,Type> typeMap)
private Symbol firstDirectIncompatibility(Type t1,
Type t2,
Type site)
boolean checkCommonOverriderIn(Symbol s1,
Symbol s2,
Type site)
void checkOverride(JCTree tree,
Symbol.MethodSymbol m)
tree - The tree from which positions are extracted
for errors.m - The overriding method.
void checkAllDefined(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c)
pos - Position to be used for error reporting.c - The class.
private Symbol.MethodSymbol firstUndef(Symbol.ClassSymbol impl,
Symbol.ClassSymbol c)
void checkNonCyclic(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type referred to.
void checkNonCyclic(JCDiagnostic.DiagnosticPosition pos,
Type.TypeVar t)
private void checkNonCyclic1(JCDiagnostic.DiagnosticPosition pos,
Type t,
java.util.Set<Type.TypeVar> seen)
private boolean checkNonCyclicInternal(JCDiagnostic.DiagnosticPosition pos,
Type t)
pos - Position to be used for error reporting.t - The type referred to.
private void noteCyclic(JCDiagnostic.DiagnosticPosition pos,
Symbol.ClassSymbol c)
void checkImplementations(JCTree.JCClassDecl tree)
tree - The class definition whose members are checked.
void checkImplementations(JCTree.JCClassDecl tree,
Symbol.ClassSymbol ic)
void checkCompatibleSupertypes(JCDiagnostic.DiagnosticPosition pos,
Type c)
pos - Position to be used for error reporting.c - The class whose interfaces are checked.
void checkClassBounds(JCDiagnostic.DiagnosticPosition pos,
Type type)
pos - Position to be used for error reporting.type - The type whose interfaces are checked.
void checkClassBounds(JCDiagnostic.DiagnosticPosition pos,
java.util.Map<Symbol.TypeSymbol,Type> seensofar,
Type type)
void checkNotRepeated(JCDiagnostic.DiagnosticPosition pos,
Type it,
java.util.Set<Type> its)
void validateAnnotationType(JCTree restype)
void validateAnnotationType(JCDiagnostic.DiagnosticPosition pos,
Type type)
void validateAnnotationMethod(JCDiagnostic.DiagnosticPosition pos,
Symbol.MethodSymbol m)
public void validateAnnotations(List<JCTree.JCAnnotation> annotations,
Symbol s)
public void validateAnnotation(JCTree.JCAnnotation a,
Symbol s)
boolean isOverrider(Symbol s)
boolean annotationApplicable(JCTree.JCAnnotation a,
Symbol s)
public void validateAnnotation(JCTree.JCAnnotation a)
void checkDeprecatedAnnotation(JCDiagnostic.DiagnosticPosition pos,
Symbol s)
void checkNonCyclicElements(JCTree.JCClassDecl tree)
void checkNonCyclicElementsInternal(JCDiagnostic.DiagnosticPosition pos,
Symbol.TypeSymbol tsym)
void checkAnnotationResType(JCDiagnostic.DiagnosticPosition pos,
Type type)
void checkCyclicConstructors(JCTree.JCClassDecl tree)
private void checkCyclicConstructor(JCTree.JCClassDecl tree,
Symbol ctor,
java.util.Map<Symbol,Symbol> callMap)
int checkOperator(JCDiagnostic.DiagnosticPosition pos,
Symbol.OperatorSymbol operator,
int tag,
Type left,
Type right)
pos - position for error reporting.operator - an operatortag - a tree tagleft - type of left hand sideright - type of right hand side
void checkDivZero(JCDiagnostic.DiagnosticPosition pos,
Symbol operator,
Type operand)
pos - Position for error reporting.operator - The operator for the expressionoperand - The right hand operand for the expressionvoid checkEmptyIf(JCTree.JCIf tree)
boolean checkUnique(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
pos - Position for error reporting.sym - The symbol.s - The scope.
boolean checkUniqueImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
pos - Position for error reporting.sym - The symbol.s - The scope
boolean checkUniqueStaticImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s)
pos - Position for error reporting.sym - The symbol.s - The scopestaticImport - Whether or not this was a static import
private boolean checkUniqueImport(JCDiagnostic.DiagnosticPosition pos,
Symbol sym,
Scope s,
boolean staticImport)
pos - Position for error reporting.sym - The symbol.s - The scope.staticImport - Whether or not this was a static importpublic void checkCanonical(JCTree tree)
private boolean isCanonical(JCTree tree)
public Warner castWarner(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type expected)
public Warner convertWarner(JCDiagnostic.DiagnosticPosition pos,
Type found,
Type expected)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||