FIR IDE: Enable ReplaceInfixOrOperatorCallFix for UNSAFE_CALL,
UNSAFE_INFIX_CALL, UNSAFE_OPERATOR_CALL.
This commit is contained in:
committed by
teamcityserver
parent
5a7f4ffc99
commit
ca7649edbb
@@ -0,0 +1,4 @@
|
||||
// "Replace with safe (?.) call" "true"
|
||||
|
||||
operator fun Int.get(row: Int, column: Int) = this
|
||||
fun foo(arg: Int?) = arg?.get(42, 13) ?: <caret>
|
||||
@@ -1,6 +1,4 @@
|
||||
// "Replace with safe (?.) call" "true"
|
||||
|
||||
operator fun Int.get(row: Int, column: Int) = this
|
||||
fun foo(arg: Int?) = arg<caret>[42, 13]
|
||||
|
||||
/* IGNORE_FIR */
|
||||
fun foo(arg: Int?) = arg<caret>[42, 13]
|
||||
@@ -1,6 +1,4 @@
|
||||
// "Replace with safe (?.) call" "true"
|
||||
|
||||
operator fun Int.get(row: Int, column: Int) = this
|
||||
fun foo(arg: Int?) = arg?.get(42, 13)
|
||||
|
||||
/* IGNORE_FIR */
|
||||
fun foo(arg: Int?) = arg?.get(42, 13)
|
||||
@@ -1,6 +1,4 @@
|
||||
// "Replace with safe (?.) call" "true"
|
||||
|
||||
operator fun Int.plus(index: Int) = this
|
||||
fun fox(arg: Int?) = arg <caret>+ 42
|
||||
|
||||
/* IGNORE_FIR */
|
||||
fun fox(arg: Int?) = arg <caret>+ 42
|
||||
@@ -1,6 +1,4 @@
|
||||
// "Replace with safe (?.) call" "true"
|
||||
|
||||
operator fun Int.plus(index: Int) = this
|
||||
fun fox(arg: Int?) = arg?.plus(42)
|
||||
|
||||
/* IGNORE_FIR */
|
||||
fun fox(arg: Int?) = arg?.plus(42)
|
||||
@@ -3,6 +3,4 @@
|
||||
operator fun Int.set(row: Int, column: Int, value: Int) {}
|
||||
fun foo(arg: Int?) {
|
||||
arg<caret>[42, 13] = 0
|
||||
}
|
||||
|
||||
/* IGNORE_FIR */
|
||||
}
|
||||
@@ -3,6 +3,4 @@
|
||||
operator fun Int.set(row: Int, column: Int, value: Int) {}
|
||||
fun foo(arg: Int?) {
|
||||
arg?.set(42, 13, 0)
|
||||
}
|
||||
|
||||
/* IGNORE_FIR */
|
||||
}
|
||||
Reference in New Issue
Block a user