9ce40cd17b
Operator priority calculation for 'this' expressions was incorrect in JetPsiUtil.getPriority(): it would return a very low value for a JetThisExpression, causing the IDE to report that parenthesis are necessary in an expression like '(this)[1]'. Fix this by making JetThisExpression not implement JetStatementExpression by removing the implements clause from JetLabelQualifiedInstanceExpression and adding it to all other subclasses of JetLabelQualifiedInstanceExpression. Fixes KT-4513.
7 lines
129 B
Kotlin
7 lines
129 B
Kotlin
class C() {
|
|
fun get(i: Int) = i + 1
|
|
|
|
// KT-4513: Unnecessary parenthesis around 'this'
|
|
val foo = (th<caret>is)[41]
|
|
}
|