Limit "always null" scope: only for !!, is and dot; senseless comparison rolled back; "smart constant" information for nulls #KT-10029 Fixed

This commit is contained in:
Mikhail Glukhikh
2015-11-23 14:50:20 +03:00
parent db42941586
commit 89e56093a2
41 changed files with 323 additions and 151 deletions
@@ -3,7 +3,7 @@ fun foo(x: String?, y: String?, z: String?, w: String?) {
<!DEBUG_INFO_SMARTCAST!>z<!>.length
else
z<!UNSAFE_CALL!>.<!>length
if (x != null || y != null || (<!ALWAYS_NULL!>x<!> != z && <!ALWAYS_NULL!>y<!> != z))
if (x != null || y != null || (<!DEBUG_INFO_CONSTANT!>x<!> != z && <!DEBUG_INFO_CONSTANT!>y<!> != z))
z<!UNSAFE_CALL!>.<!>length
else
<!ALWAYS_NULL!>z<!><!UNSAFE_CALL!>.<!>length