1 // WITH_RUNTIME 2 // TEST PROCESSOR: ConstPropertiesProcessor 3 // EXPECTED: 4 // insideCompanionConstCompiled 5 // insideCompanionConstSource 6 // insideObjectConstCompiled 7 // insideObjectConstSource 8 // topLevelConstCompiled 9 // topLevelConstSource 10 // END 11 // MODULE: lib 12 // FILE: compiledProperties.kt 13 package foo.compiled 14 15 const val topLevelConstCompiled: String = "hello" 16 val topLevelCompiled: String = "hello" <lambda>null17val topLevelDelegatedCompiled by lazy { "hello" } 18 var topLevelVarCompiled: String = "hello" 19 val topLevelCustomGetterCompiled: String get() = "hello" 20 object TestObject { 21 const val insideObjectConstCompiled: Boolean = true 22 val insideObjectCompiled: String = "hello" <lambda>null23 val insideObjectDelegatedCompiled by lazy { "hello" } 24 var insideVarObjectCompiled: String = "hello" 25 val insideObjectCustomGetterCompiled: String get() = "hello" 26 } 27 interface Foo { 28 val abstractCompiled: Long 29 val abstractWithDefaultCompiled: Long get() = 100L 30 companion object { 31 const val insideCompanionConstCompiled: Int = 34 32 } 33 } 34 35 // MODULE: main(lib) 36 // FILE: sourceProperties.kt 37 package foo.source 38 39 const val topLevelConstSource: String = "hello" 40 val topLevelSource: String = "hello" <lambda>null41val topLevelDelegatedSource by lazy { "hello" } 42 var topLevelVarSource: String = "hello" 43 val topLevelCustomGetterSource: String get() = "hello" 44 object TestObject { 45 const val insideObjectConstSource: Boolean = true 46 val insideObjectSource: String = "hello" <lambda>null47 val insideObjectDelegatedSource by lazy { "hello" } 48 var insideVarObjectSource: String = "hello" 49 val insideObjectCustomGetterSource: String get() = "hello" 50 } 51 interface Foo { 52 val abstractSource: Long 53 val abstractWithDefaultSource: Long get() = 100L 54 companion object { 55 const val insideCompanionConstSource: Int = 34 56 } 57 } 58