Improve generic parameters

This commit is contained in:
Him188 2020-07-13 13:34:36 +08:00
parent 31aea380eb
commit abf33bb214

View File

@ -50,7 +50,7 @@ public interface PluginLoader<P : Plugin, D : PluginDescription> {
public fun disable(plugin: P)
}
public inline fun <D : PluginDescription, P : Plugin> PluginLoader<P, D>.getDescription(plugin: P): D =
public inline fun <D : PluginDescription, P : Plugin> PluginLoader<in P, out D>.getDescription(plugin: P): D =
plugin.description
public open class PluginLoadException : RuntimeException {