Add intention to introduce import alias

#KT-16118 Fixed
 #KT-30007 Fixed
This commit is contained in:
Dmitry Gridin
2019-02-21 10:38:43 +03:00
parent 6bf119b262
commit 147521d6cb
94 changed files with 893 additions and 4 deletions
@@ -2,5 +2,6 @@
// ERROR: This type is final, so it cannot be inherited from
// ACTION: Add names to call arguments
// ACTION: Do not show hints for current method
// ACTION: Introduce import alias
data class A(val x: Int)
class B: A<caret>(42)
@@ -1,4 +1,5 @@
// "class org.jetbrains.kotlin.idea.quickfix.AddModifierFix" "false"
// ERROR: This type is final, so it cannot be inherited from
// ACTION: Create test
// ACTION: Introduce import alias
class foo : <caret>JavaClass() {}
@@ -1,5 +1,6 @@
// "class org.jetbrains.kotlin.idea.quickfix.AddModifierFix" "false"
// ACTION: Create test
// ACTION: Inline type parameter
// ACTION: Introduce import alias
// ACTION: Remove final upper bound
class foo<T : <caret>JavaClass>() {}
@@ -1,5 +1,6 @@
// "Add 'lateinit' modifier" "false"
// ACTION: Add initializer
// ACTION: Introduce import alias
// ACTION: Make 'a' abstract
// ACTION: Move to constructor parameters
// ACTION: Move to constructor
+1
View File
@@ -1,4 +1,5 @@
// "Make bar suspend" "false"
// ACTION: Introduce import alias
// ERROR: Suspend function 'foo' should be called only from a coroutine or another suspend function
suspend fun foo() {}
+1
View File
@@ -1,5 +1,6 @@
// "Make bar suspend" "false"
// ACTION: Convert property initializer to getter
// ACTION: Introduce import alias
// ERROR: Suspend function 'foo' should be called only from a coroutine or another suspend function
suspend fun foo() = 42