K2: add reproducer for KT-54275
This commit is contained in:
committed by
Space Team
parent
7f6bd2ab1e
commit
d491eba629
Vendored
+17
@@ -0,0 +1,17 @@
|
||||
typealias EventHandler<E> = (e: E) -> Unit
|
||||
|
||||
class EventListener<E: Event>() {
|
||||
|
||||
companion object {
|
||||
|
||||
inline operator fun <reified E: Event> invoke(
|
||||
noinline callback: EventHandler<E>,
|
||||
): EventListener<E> = TODO()
|
||||
}
|
||||
}
|
||||
|
||||
inline fun <reified E: Event> EventHandler<E>.withPriority() = EventListener(this)
|
||||
|
||||
inline fun <reified E: Event> EventHandler<E>.withDefaultPriority() = withPriority()
|
||||
|
||||
abstract class Event
|
||||
Reference in New Issue
Block a user