Change overriddenDescriptors' type from Set to Collection

So that the easiest way of constructing a HashSet in the implementation will be
not the only possible way to implement getOverriddenDescriptors(). If there's
not too many overridden descriptors, an implementation may decide to return a
small list for example instead
This commit is contained in:
Alexander Udalov
2015-08-06 04:27:59 +03:00
parent d328727cea
commit f3857cbb89
22 changed files with 49 additions and 61 deletions
@@ -59,7 +59,7 @@ public abstract class CallableRefactoring<T: CallableDescriptor>(
return false
}
private fun getClosestModifiableDescriptors(): Set<CallableDescriptor> {
private fun getClosestModifiableDescriptors(): Collection<CallableDescriptor> {
return when (kind) {
DECLARATION -> {
Collections.singleton(callableDescriptor)