mirror of
https://github.com/github/codeql.git
synced 2026-05-05 05:35:13 +02:00
Kotlin: Enhance methods test
This commit is contained in:
12
java/ql/test/kotlin/library-tests/methods/delegates.kt
Normal file
12
java/ql/test/kotlin/library-tests/methods/delegates.kt
Normal file
@@ -0,0 +1,12 @@
|
||||
import kotlin.properties.Delegates
|
||||
|
||||
class MyClass {
|
||||
val lazyProp by lazy {
|
||||
5
|
||||
}
|
||||
|
||||
var observableProp: String by Delegates.observable("<none>") {
|
||||
prop, old, new ->
|
||||
println("Was $old, now $new")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user