[FIR] Fix crash caused by cast of raw type to simple type
#KT-66552 Fixed
This commit is contained in:
committed by
Space Team
parent
cec36355b2
commit
786c37286c
@@ -0,0 +1,25 @@
|
||||
// FIR_IDENTICAL
|
||||
// ISSUE: KT-66552
|
||||
|
||||
// FILE: JsStubElementType.java
|
||||
public interface JsStubElementType<E, S extends JsStubElement<E>> {}
|
||||
|
||||
// FILE: JsStubElement.java
|
||||
public interface JsStubElement<T> {
|
||||
<E, S extends JsStubElement<E>> void findChildStubByType(JsStubElementType<E, S> childStubType);
|
||||
}
|
||||
|
||||
// FILE: FromJava.java
|
||||
public interface FromJava {
|
||||
JsStubElement RAW_TYPED_STUB = null;
|
||||
}
|
||||
|
||||
// FILE: Kotlin.kt
|
||||
interface JsStubElementSubType: JsStubElement<Any>
|
||||
|
||||
fun test(childStubType: JsStubElementType<Any, JsStubElement<Any>>) {
|
||||
val rawTypedStub = FromJava.RAW_TYPED_STUB
|
||||
if (rawTypedStub is JsStubElementSubType) {
|
||||
rawTypedStub.findChildStubByType(childStubType)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user