Change part class naming scheme
update tests depending on part class naming
This commit is contained in:
committed by
Michael Bogdanov
parent
801d10229b
commit
a47eaa2cb5
@@ -23,9 +23,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambda.1.kt
|
||||
//_DefaultPackage
|
||||
//Lambda_1Kt
|
||||
//+ 2 lambda.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/Lambda_2Kt
|
||||
//*L
|
||||
//1#1,46:1
|
||||
//4#2:47
|
||||
@@ -37,9 +37,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambda.2.kt
|
||||
//builders/BuildersPackage$lambda_2$HASH$call$1
|
||||
//builders/Lambda_2Kt$call$1
|
||||
//+ 2 lambda.1.kt
|
||||
//_DefaultPackage$lambda_1$HASH
|
||||
//Lambda_1Kt
|
||||
//*L
|
||||
//1#1,18:1
|
||||
//8#2:19
|
||||
|
||||
@@ -12,7 +12,7 @@ inline fun call(inlineOptions(InlineOption.ONLY_LOCAL_RETURN) init: () -> Unit)
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambda.2.kt
|
||||
//builders/BuildersPackage$lambda_2$HASH$call$1
|
||||
//builders/Lambda_2Kt$call$1
|
||||
//*L
|
||||
//1#1,18:1
|
||||
//*E
|
||||
@@ -25,9 +25,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambdaOnCallSite.1.kt
|
||||
//_DefaultPackage
|
||||
//LambdaOnCallSite_1Kt
|
||||
//+ 2 lambdaOnCallSite.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/LambdaOnCallSite_2Kt
|
||||
//*L
|
||||
//1#1,34:1
|
||||
//4#2:35
|
||||
|
||||
+4
-4
@@ -25,9 +25,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambdaOnInlineCallSite.1.kt
|
||||
//_DefaultPackage
|
||||
//LambdaOnInlineCallSite_1Kt
|
||||
//+ 2 lambdaOnInlineCallSite.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/LambdaOnInlineCallSite_2Kt
|
||||
//*L
|
||||
//1#1,56:1
|
||||
//4#2:57
|
||||
@@ -39,7 +39,7 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambdaOnInlineCallSite.1.kt
|
||||
//_DefaultPackage$lambdaOnInlineCallSite_1$HASH$test$1$1
|
||||
//LambdaOnInlineCallSite_1Kt$test$1$1
|
||||
//*L
|
||||
//1#1,56:1
|
||||
//*E
|
||||
@@ -50,7 +50,7 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 lambdaOnInlineCallSite.1.kt
|
||||
//_DefaultPackage$lambdaOnInlineCallSite_1$HASH$test$1$1
|
||||
//LambdaOnInlineCallSite_1Kt$test$1$1
|
||||
//*L
|
||||
//1#1,56:1
|
||||
//*E
|
||||
@@ -22,9 +22,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 object.1.kt
|
||||
//_DefaultPackage
|
||||
//Object_1Kt
|
||||
//+ 2 object.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/Object_2Kt
|
||||
//*L
|
||||
//1#1,45:1
|
||||
//4#2,5:46
|
||||
@@ -36,9 +36,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 object.2.kt
|
||||
//builders/BuildersPackage$object_2$HASH$call$1
|
||||
//builders/Object_2Kt$call$1
|
||||
//+ 2 object.1.kt
|
||||
//_DefaultPackage$object_1$HASH
|
||||
//Object_1Kt
|
||||
//*L
|
||||
//1#1,21:1
|
||||
//8#2:22
|
||||
|
||||
@@ -15,7 +15,7 @@ inline fun call(inlineOptions(InlineOption.ONLY_LOCAL_RETURN) init: () -> Unit)
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 object.2.kt
|
||||
//builders/BuildersPackage$object_2$HASH$call$1
|
||||
//builders/Object_2Kt$call$1
|
||||
//*L
|
||||
//1#1,21:1
|
||||
//*E
|
||||
@@ -27,9 +27,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 objectOnCallSite.1.kt
|
||||
//_DefaultPackage
|
||||
//ObjectOnCallSite_1Kt
|
||||
//+ 2 objectOnCallSite.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/ObjectOnCallSite_2Kt
|
||||
//*L
|
||||
//1#1,36:1
|
||||
//4#2:37
|
||||
|
||||
+4
-4
@@ -27,9 +27,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 objectOnInlineCallSite.1.kt
|
||||
//_DefaultPackage
|
||||
//ObjectOnInlineCallSite_1Kt
|
||||
//+ 2 objectOnInlineCallSite.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/ObjectOnInlineCallSite_2Kt
|
||||
//*L
|
||||
//1#1,58:1
|
||||
//4#2:59
|
||||
@@ -41,7 +41,7 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 objectOnInlineCallSite.1.kt
|
||||
//_DefaultPackage$objectOnInlineCallSite_1$HASH$test$1$1
|
||||
//ObjectOnInlineCallSite_1Kt$test$1$1
|
||||
//*L
|
||||
//1#1,58:1
|
||||
//*E
|
||||
@@ -52,7 +52,7 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 objectOnInlineCallSite.1.kt
|
||||
//_DefaultPackage$objectOnInlineCallSite_1$HASH$test$1$1
|
||||
//ObjectOnInlineCallSite_1Kt$test$1$1
|
||||
//*L
|
||||
//1#1,58:1
|
||||
//*E
|
||||
+2
-2
@@ -15,9 +15,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 assertion.1.kt
|
||||
//_DefaultPackage
|
||||
//Assertion_1Kt
|
||||
//+ 2 assertion.2.kt
|
||||
//test/TestPackage
|
||||
//test/Assertion_2Kt
|
||||
//*L
|
||||
//1#1,25:1
|
||||
//15#2,7:26
|
||||
|
||||
+2
-2
@@ -20,7 +20,7 @@ public inline fun massert(value: Boolean, message: Any = "Assertion failed") {
|
||||
}
|
||||
}
|
||||
|
||||
//TODO SHOUDL BE ABSENT
|
||||
//TODO SHOULD BE ABSENT
|
||||
|
||||
//SMAP
|
||||
//assertion.2.kt
|
||||
@@ -28,7 +28,7 @@ public inline fun massert(value: Boolean, message: Any = "Assertion failed") {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 assertion.2.kt
|
||||
//test/TestPackage
|
||||
//test/Assertion_2Kt
|
||||
//*L
|
||||
//1#1,34:1
|
||||
//*E
|
||||
+1
-1
@@ -16,7 +16,7 @@ inline fun test(p: () -> String): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 oneFile.1.kt
|
||||
//_DefaultPackage
|
||||
//OneFile_1Kt
|
||||
//*L
|
||||
//1#1,22:1
|
||||
//*E
|
||||
@@ -12,9 +12,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 inlineComponent.1.kt
|
||||
//_DefaultPackage
|
||||
//InlineComponent_1Kt
|
||||
//+ 2 inlineComponent.2.kt
|
||||
//zzz/ZzzPackage
|
||||
//zzz/InlineComponent_2Kt
|
||||
//*L
|
||||
//1#1,21:1
|
||||
//5#2,3:22
|
||||
|
||||
@@ -15,9 +15,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 inlineIterator.1.kt
|
||||
//_DefaultPackage
|
||||
//InlineIterator_1Kt
|
||||
//+ 2 inlineIterator.2.kt
|
||||
//zzz/ZzzPackage
|
||||
//zzz/InlineIterator_2Kt
|
||||
//*L
|
||||
//1#1,24:1
|
||||
//5#2:25
|
||||
|
||||
+2
-2
@@ -26,9 +26,9 @@ fun box(): String {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 smap.1.kt
|
||||
//_DefaultPackage
|
||||
//Smap_1Kt
|
||||
//+ 2 smap.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/Smap_2Kt
|
||||
//*L
|
||||
//1#1,38:1
|
||||
//16#2:39
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ inline fun html(init: () -> Unit) {
|
||||
//*S Kotlin
|
||||
//*F
|
||||
//+ 1 smap.2.kt
|
||||
//builders/BuildersPackage
|
||||
//builders/Smap_2Kt
|
||||
//*L
|
||||
//1#1,28:1
|
||||
//*E
|
||||
+2
-2
@@ -12,8 +12,8 @@ fun box(): String {
|
||||
return "Fail: very small stack trace, should at least have current function and JUnit reflective calls: ${Arrays.toString(st)}"
|
||||
}
|
||||
val top = st[0]
|
||||
if (!(top.getClassName().startsWith("_DefaultPackage") && top.getMethodName() == "box")) {
|
||||
return "Fail: top stack trace element should be box() from default package, but was $top"
|
||||
if (!(top.getClassName() == "PlatformTypeAssertionStackTraceKt" && top.getMethodName() == "box")) {
|
||||
return "Fail: top stack trace element should be PlatformTypeAssertionStackTraceKt.box() from default package, but was $top"
|
||||
}
|
||||
return "OK"
|
||||
}
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "invoke") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = classInLambda.javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.endsWith("\$box\$classInLambda\$1")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "ClassInLambdaKt\$box\$classInLambda\$1") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = classInLambda.javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "class has a declaring class"
|
||||
|
||||
Vendored
+1
-1
@@ -7,7 +7,7 @@ fun box(): String {
|
||||
if (enclosingMethod != null) return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("functionExpressionInProperty")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "FunctionExpressionInPropertyKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
+1
-1
@@ -6,7 +6,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "box") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("lambdaInFunction")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInFunctionKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "invoke") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.contains("\$box\$l\$1")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInLambdaKt\$box\$l\$1") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
Vendored
+2
-2
@@ -12,10 +12,10 @@ fun box(): String {
|
||||
|
||||
val javaClass = l.a.javaClass
|
||||
val enclosingMethod = javaClass.getEnclosingConstructor()!!.getName()
|
||||
if (!enclosingMethod.startsWith("_DefaultPackage\$") || !enclosingMethod.endsWith("\$box\$L")) return "ctor: $enclosingMethod"
|
||||
if (enclosingMethod != "LambdaInLocalClassConstructorKt\$box\$L") return "ctor: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.endsWith("\$box\$L")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInLocalClassConstructorKt\$box\$L") return "enclosing class: $enclosingClass"
|
||||
|
||||
if (enclosingMethod != enclosingClass) return "$enclosingClass != $enclosingMethod"
|
||||
|
||||
|
||||
Vendored
+2
-2
@@ -7,10 +7,10 @@ fun box(): String {
|
||||
|
||||
val javaClass = l.a.javaClass
|
||||
val enclosingMethod = javaClass.getEnclosingConstructor()!!.getName()
|
||||
if (!enclosingMethod.startsWith("_DefaultPackage\$") || !enclosingMethod.endsWith("\$box\$L")) return "ctor: $enclosingMethod"
|
||||
if (enclosingMethod != "LambdaInLocalClassSuperCallKt\$box\$L") return "ctor: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.endsWith("\$box\$L")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInLocalClassSuperCallKt\$box\$L") return "enclosing class: $enclosingClass"
|
||||
|
||||
if (enclosingMethod != enclosingClass) return "$enclosingClass != $enclosingMethod"
|
||||
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "invoke") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.contains("\$box$1")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInLocalFunctionKt\$box$1") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
Vendored
+1
-1
@@ -10,7 +10,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "foo") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.contains("\$box\$C")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInMemberFunctionInLocalClassKt\$box\$C") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
+2
-2
@@ -13,10 +13,10 @@ fun box(): String {
|
||||
|
||||
val javaClass = l.a.javaClass
|
||||
val enclosingMethod = javaClass.getEnclosingConstructor()!!.getName()
|
||||
if (!enclosingMethod.startsWith("_DefaultPackage\$") || !enclosingMethod.endsWith("\$box\$l\$1")) return "ctor: $enclosingMethod"
|
||||
if (enclosingMethod != "LambdaInObjectExpressionKt\$box\$l\$1") return "ctor: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.endsWith("\$box\$l\$1")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInObjectExpressionKt\$box\$l\$1") return "enclosing class: $enclosingClass"
|
||||
|
||||
if (enclosingMethod != enclosingClass) return "$enclosingClass != $enclosingMethod"
|
||||
|
||||
|
||||
Vendored
+1
-1
@@ -11,7 +11,7 @@ fun box(): String {
|
||||
if (enclosingMethod != "box") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || enclosingClass != l.javaClass.getEnclosingClass()!!.getName())
|
||||
if (enclosingClass != "LambdaInObjectLiteralSuperCallKt" || enclosingClass != l.javaClass.getEnclosingClass()!!.getName())
|
||||
return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ val l: Any = {}
|
||||
|
||||
fun box(): String {
|
||||
val enclosingClass = l.javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("lambdaInPackage")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInPackageKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val enclosingConstructor = l.javaClass.getEnclosingConstructor()
|
||||
if (enclosingConstructor != null) return "enclosing constructor found: $enclosingConstructor"
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "getL") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = l.javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("lambdaInPropertyGetter")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInPropertyGetterKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = l.javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "setL") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = l.javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("lambdaInPropertySetter")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "LambdaInPropertySetterKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = l.javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
Vendored
+1
-1
@@ -7,7 +7,7 @@ fun box(): String {
|
||||
if (enclosingMethod != null) return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage") || !enclosingClass.contains("namedFunctionExpressionInProperty")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "NamedFunctionExpressionInPropertyKt") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass"
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ fun box(): String {
|
||||
if (enclosingMethod?.getName() != "invoke") return "method: $enclosingMethod"
|
||||
|
||||
val enclosingClass = objectInLambda.javaClass.getEnclosingClass()!!.getName()
|
||||
if (!enclosingClass.startsWith("_DefaultPackage\$") || !enclosingClass.endsWith("\$box\$objectInLambda\$1")) return "enclosing class: $enclosingClass"
|
||||
if (enclosingClass != "ObjectInLambdaKt\$box\$objectInLambda\$1") return "enclosing class: $enclosingClass"
|
||||
|
||||
val declaringClass = objectInLambda.javaClass.getDeclaringClass()
|
||||
if (declaringClass != null) return "anonymous object has a declaring class"
|
||||
|
||||
@@ -17,6 +17,6 @@ fun test() {
|
||||
(::local)()
|
||||
}
|
||||
|
||||
// 3 GETSTATIC _DefaultPackage\$.+\$test\$1\.INSTANCE\$
|
||||
// 1 GETSTATIC _DefaultPackage\$.+\$test\$2\.INSTANCE\$
|
||||
// 1 GETSTATIC _DefaultPackage\$.+\$test\$3\.INSTANCE\$
|
||||
// 3 GETSTATIC ConstClosureOptimizationKt\$test\$1\.INSTANCE\$
|
||||
// 1 GETSTATIC ConstClosureOptimizationKt\$test\$2\.INSTANCE\$
|
||||
// 1 GETSTATIC ConstClosureOptimizationKt\$test\$3\.INSTANCE\$
|
||||
|
||||
@@ -5,4 +5,4 @@ fun simpleFoo(s: Int = 111) {
|
||||
}
|
||||
|
||||
// 1 BIPUSH 111
|
||||
// 1 INVOKESTATIC foo/FooPackage.+\.simpleFoo\$default \(II\)V
|
||||
// 1 INVOKESTATIC foo/DefaultDelegationKt.simpleFoo\$default \(II\)V
|
||||
|
||||
@@ -4,4 +4,4 @@ fun foo() {
|
||||
|
||||
// assert function will be inlined, and we assure that there are no calls via package part, but is call via package facade in inlined code
|
||||
// 0 INVOKESTATIC kotlin\/KotlinPackage.+\.getASSERTIONS_ENABLED \(\)Z
|
||||
// 1 INVOKESTATIC kotlin\/KotlinPackage\.getASSERTIONS_ENABLED \(\)Z
|
||||
// 1 INVOKESTATIC kotlin\/AssertionsJVMKt\.getASSERTIONS_ENABLED \(\)Z
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
fun foo(a: Int = 1) {}
|
||||
|
||||
// 0 _DefaultPackage.foo
|
||||
// 3 INVOKESTATIC _DefaultPackage.+
|
||||
// 3 INVOKESTATIC TopLevelFunWithDefaultArgsKt\.foo
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
fun Int.test1() {}
|
||||
|
||||
fun test2() {
|
||||
1.test1()
|
||||
}
|
||||
|
||||
// 2 INVOKESTATIC A1Kt.test1 \(I\)V
|
||||
// 1 INVOKESTATIC A1Kt.test2 \(\)V
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
package a
|
||||
|
||||
fun test1() {}
|
||||
|
||||
// 2 INVOKESTATIC a/A1Kt.test1 \(\)V
|
||||
// 1 INVOKESTATIC b/A2Kt.test2 \(\)V
|
||||
@@ -0,0 +1,8 @@
|
||||
fun test1() {}
|
||||
|
||||
fun test2() {
|
||||
test1()
|
||||
}
|
||||
|
||||
// 2 INVOKESTATIC A1Kt.test1 \(\)V
|
||||
// 1 INVOKESTATIC A1Kt.test2 \(\)V
|
||||
@@ -0,0 +1,6 @@
|
||||
package a
|
||||
|
||||
val prop = 1
|
||||
|
||||
// 2 INVOKESTATIC a/A1Kt.getProp \(\)I
|
||||
// 1 GETSTATIC a/A1Kt.prop \: I
|
||||
@@ -0,0 +1,9 @@
|
||||
package a
|
||||
|
||||
val prop: Int = 0
|
||||
get() {
|
||||
return $prop + 1
|
||||
}
|
||||
|
||||
// 2 INVOKESTATIC a/A1Kt.getProp \(\)I
|
||||
// 1 GETSTATIC a/A1Kt.prop \: I
|
||||
Reference in New Issue
Block a user