Minor: remove redundant implementations of ResolutionContext#self
This commit is contained in:
-5
@@ -90,9 +90,4 @@ public class BasicCallResolutionContext extends CallResolutionContext<BasicCallR
|
|||||||
return create(trace, scope, call, expectedType, dataFlowInfo, contextDependency, checkArguments, resolutionResultsCache,
|
return create(trace, scope, call, expectedType, dataFlowInfo, contextDependency, checkArguments, resolutionResultsCache,
|
||||||
labelResolver, dataFlowInfoForArguments, callResolverExtension, isAnnotationContext);
|
labelResolver, dataFlowInfoForArguments, callResolverExtension, isAnnotationContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected BasicCallResolutionContext self() {
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
-5
@@ -98,9 +98,4 @@ public final class CallCandidateResolutionContext<D extends CallableDescriptor>
|
|||||||
candidateCall, tracing, trace, scope, call, expectedType, dataFlowInfo, contextDependency, checkArguments,
|
candidateCall, tracing, trace, scope, call, expectedType, dataFlowInfo, contextDependency, checkArguments,
|
||||||
resolutionResultsCache, labelResolver, dataFlowInfoForArguments, callResolverExtension, isAnnotationContext);
|
resolutionResultsCache, labelResolver, dataFlowInfoForArguments, callResolverExtension, isAnnotationContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected CallCandidateResolutionContext<D> self() {
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-1
@@ -69,7 +69,11 @@ public abstract class ResolutionContext<Context extends ResolutionContext<Contex
|
|||||||
@NotNull LabelResolver labelResolver
|
@NotNull LabelResolver labelResolver
|
||||||
);
|
);
|
||||||
|
|
||||||
protected abstract Context self();
|
@NotNull
|
||||||
|
private Context self() {
|
||||||
|
//noinspection unchecked
|
||||||
|
return (Context) this;
|
||||||
|
}
|
||||||
|
|
||||||
@NotNull
|
@NotNull
|
||||||
public Context replaceBindingTrace(@NotNull BindingTrace trace) {
|
public Context replaceBindingTrace(@NotNull BindingTrace trace) {
|
||||||
|
|||||||
-5
@@ -54,9 +54,4 @@ public class SimpleResolutionContext extends ResolutionContext<SimpleResolutionC
|
|||||||
trace, scope, expectedType, dataFlowInfo, contextDependency, resolutionResultsCache, labelResolver, callResolverExtension,
|
trace, scope, expectedType, dataFlowInfo, contextDependency, resolutionResultsCache, labelResolver, callResolverExtension,
|
||||||
isAnnotationContext);
|
isAnnotationContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected SimpleResolutionContext self() {
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -119,11 +119,6 @@ public class ResolutionTask<D extends CallableDescriptor, F extends D> extends C
|
|||||||
return newTask;
|
return newTask;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected ResolutionTask<D, F> self() {
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ResolutionTask<D, F> replaceCall(@NotNull Call newCall) {
|
public ResolutionTask<D, F> replaceCall(@NotNull Call newCall) {
|
||||||
return new ResolutionTask<D, F>(
|
return new ResolutionTask<D, F>(
|
||||||
candidates, reference, tracing, trace, scope, newCall, expectedType, dataFlowInfo, contextDependency, checkArguments,
|
candidates, reference, tracing, trace, scope, newCall, expectedType, dataFlowInfo, contextDependency, checkArguments,
|
||||||
|
|||||||
-5
@@ -111,11 +111,6 @@ public class ExpressionTypingContext extends ResolutionContext<ExpressionTypingC
|
|||||||
isAnnotationContext);
|
isAnnotationContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected ExpressionTypingContext self() {
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
///////////// LAZY ACCESSORS
|
///////////// LAZY ACCESSORS
|
||||||
|
|
||||||
public CompileTimeConstantChecker getCompileTimeConstantChecker() {
|
public CompileTimeConstantChecker getCompileTimeConstantChecker() {
|
||||||
|
|||||||
Reference in New Issue
Block a user