Remove dependencies on data flow aware expression type in BindingContext

`BindingContext.getType`'s behaviour on argument expression has been different for OI and NI for some time.
New inference used to rewrite argument's type after smartcast, which led to missing subsequent smartcasts in some cases.
This commit makes retrieval of smartcasted argument type explicit.
This commit is contained in:
Pavel Kirpichenkov
2019-12-30 18:50:51 +03:00
parent 4d11fac365
commit 69e800c695
7 changed files with 43 additions and 28 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
internal class C {
fun foo(s: String?): String? {
fun foo(s: String?): String {
return s ?: ""
}
}