Fix check for instance for types with compatible upper bounds

#KT-5246 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2017-04-03 05:14:15 +03:00
parent 1e56815b3b
commit bff9ebc0d5
6 changed files with 160 additions and 5 deletions
@@ -0,0 +1,14 @@
// check that there is no SOE on checking for instance
interface Visitor<T>
interface Acceptor<T>
class Word : Acceptor<Visitor<Word>>
class V : Visitor<Word>
class S<T : Acceptor<U>, U : Visitor<T>>(val visitor: U, val acceptor: T) {
fun test() {
visitor is V
acceptor is Word
}
}