Create from Usage: Implement "Create type alias" quickfix

#KT-12904 Fixed
This commit is contained in:
Alexey Sedunov
2016-07-20 14:34:49 +03:00
parent 17edbac72b
commit 6a2edabbd4
50 changed files with 555 additions and 101 deletions
@@ -119,7 +119,7 @@ class NewDeclarationNameValidator(
if (this is KtCallableDeclaration && receiverTypeReference != null) return false
return when(target) {
Target.VARIABLES -> this is KtVariableDeclaration
Target.FUNCTIONS_AND_CLASSES -> this is KtNamedFunction || this is KtClassOrObject
Target.FUNCTIONS_AND_CLASSES -> this is KtNamedFunction || this is KtClassOrObject || this is KtTypeAlias
}
}
}