[IR] Add special preprocessors for ir interpreter
These preprocessors allow us to modify IR at first and only after that try to evaluate. With this we can drop `KCallableNamePropertyLowering`.
This commit is contained in:
+2
@@ -15,6 +15,7 @@ const val methodName = A::foo.<!EVALUATED("foo")!>name<!>
|
||||
const val suspendMethodName = A::bar.<!EVALUATED("bar")!>name<!>
|
||||
const val className = ::A.<!EVALUATED("<init>")!>name<!>
|
||||
const val topLevelPropName = ::topLevelProp.<!EVALUATED("topLevelProp")!>name<!>
|
||||
const val nameInComplexExpression = A::OK.<!EVALUATED("OK")!>name<!> <!EVALUATED("OK!")!>+ "!"<!>
|
||||
|
||||
// STOP_EVALUATION_CHECKS
|
||||
fun box(): String {
|
||||
@@ -24,5 +25,6 @@ fun box(): String {
|
||||
if (suspendMethodName.id() != "bar") return "Fail 3.2"
|
||||
if (className.id() != "<init>") return "Fail 4"
|
||||
if (topLevelPropName.id() != "topLevelProp") return "Fail 5"
|
||||
if (nameInComplexExpression.id() != "OK!") return "Fail 5"
|
||||
return "OK"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user