Files
kotlin-fork/compiler/testData/diagnostics/testsWithStdLib
Dmitry Savvinov e483f83666 Make 'is'-operator more stupid
Consider following expression: 'call() is Foo'. Suppose that we know
something about the 'call()', e.g. 'returns(foo) -> <condition>'

Previously, we've tried to re-use knowledge about 'call()', constructing
some smart clause, like 'returns(true) -> foo is Foo && <condition>'.

The conceptual error here is that *we can't* argue that <condition>
holds. Imagine that 'call()' actually has unspecified 'returns(foo2) ->
<!condition>', and 'foo2 is Foo' also holds. Then we would get
'returns(true) -> foo2 is Foo && <condition>' <=> 'returns(true) ->
<condition>' for the whole call, which is not correct.

More concrete example would be something like:
'if (!x.isNullOrEmpty() is Boolean)'

^KT-27241 Fixed
2019-01-17 12:47:27 +03:00
..
2017-05-15 11:24:35 +03:00
2019-01-17 12:47:27 +03:00
2018-09-11 12:34:09 +03:00
2018-09-11 12:34:09 +03:00
2018-02-05 13:38:06 +01:00
2018-11-20 19:36:50 +03:00
2018-11-20 19:36:50 +03:00