benleggiero
08/07/2017, 1:43 AMopen class Queue<Element>(protected var backingList: MutableList<Element> = mutableListOf()) {
fun listValue():List<Element> = List(*(backingList.toTypedArray().copyOf()))
}
Error:
Error:(44, 56) Kotlin: Cannot use 'Element' as reified type parameter. Use a class instead.
2 replies
@elizarov but reified is only applicable to local generic types for inline functions, and I don't see any way to make that happen