Initialization analysis : more accurate handling of non-local variables while merging data #KT-14304 Fixed

This commit is contained in:
Mikhail Glukhikh
2016-10-20 13:41:07 +03:00
parent bba34e0caa
commit a19d178867
19 changed files with 1053 additions and 51 deletions
@@ -24,7 +24,7 @@ L0:
r(1) -> <v1> INIT: in: {bar=D, x=D} out: {bar=D, x=D}
w(x|<v1>) INIT: in: {bar=D, x=D} out: {bar=D, x=ID}
2 jmp?(L2) INIT: in: {bar=D} out: {bar=D}
d(fun foo() { val a = 2 }) INIT: in: {bar=-} out: {bar=-}
d(fun foo() { val a = 2 }) INIT: in: {bar=I?} out: {bar=I?}
L2 [after local declaration]:
r(object { init { val x = 1 } fun foo() { val a = 2 } }) -> <v2> INIT: in: {bar=D} out: {bar=D}
w(bar|<v2>) INIT: in: {bar=D} out: {bar=ID}
@@ -53,5 +53,5 @@ L4:
error:
<ERROR> INIT: in: {} out: {}
sink:
<SINK> INIT: in: {bar=-} out: {bar=-} USE: in: {} out: {}
<SINK> INIT: in: {bar=I?} out: {bar=I?} USE: in: {} out: {}
=====================