blob: 9d344f7e2dc8f18e55022eeac153e5af7d5fa851 [file] [log] [blame]
== foo ==
fun foo() {
val a = 1
val b: Int
b = 2
42
}
---------------------
L0:
1 <START> INIT: in: {} out: {} USE: in: {} out: {}
2 mark({ val a = 1 val b: Int b = 2 42 })
v(val a = 1) INIT: in: {} out: {}
r(1) -> <v0> INIT: in: {} out: {}
w(a|<v0>) INIT: in: {} out: {}
v(val b: Int) INIT: in: {} out: {b=D}
r(2) -> <v1> INIT: in: {b=D} out: {b=D} USE: in: {b=ONLY_WRITTEN_NEVER_READ} out: {b=ONLY_WRITTEN_NEVER_READ}
w(b|<v1>) INIT: in: {b=D} out: {b=ID} USE: in: {} out: {b=ONLY_WRITTEN_NEVER_READ}
r(42) -> <v2> INIT: in: {b=ID} out: {b=ID}
L1:
1 <END> INIT: in: {} out: {}
error:
<ERROR>
sink:
<SINK> USE: in: {} out: {}
=====================
== bar ==
fun bar(foo: Foo) {
foo.c
foo.c = 2
42
}
---------------------
L0:
1 <START> INIT: in: {} out: {}
v(foo: Foo) INIT: in: {} out: {}
magic[FAKE_INITIALIZER](foo: Foo) -> <v0> INIT: in: {} out: {}
w(foo|<v0>) INIT: in: {} out: {}
2 mark({ foo.c foo.c = 2 42 }) INIT: in: {} out: {}
mark(foo.c)
r(foo) -> <v1>
r(c|<v1>) -> <v2>
r(foo) -> <v3>
r(2) -> <v4>
w(foo.c|<v3>, <v4>)
r(42) -> <v5>
L1:
1 <END>
error:
<ERROR>
sink:
<SINK> USE: in: {} out: {}
=====================
== Foo ==
interface Foo {
var c: Int
}
---------------------
L0:
1 <START> INIT: in: {} out: {}
v(var c: Int) INIT: in: {} out: {}
L1:
<END> INIT: in: {} out: {}
error:
<ERROR>
sink:
<SINK> USE: in: {} out: {}
=====================