You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Concretely, maybe this line can be rewritten? If using T::class can be avoided, there's no need for the function to be reified, thus allowing it to be used in non-inline generic functions.
My use case is as follows: we are building a internal library where we want to write a class that handles certain operations with a MongoDB database, but the concrete type can vary between different usages of the library. It is impossible to write this class using inline functions and reified generics, so we must use non-reified functions.
The text was updated successfully, but these errors were encountered:
I'd would like to ask why this function is reified, and whether it can be made non-reified?
kmongo/kmongo-coroutine-core/src/main/kotlin/org/litote/kmongo/coroutine/CoroutineCollection.kt
Line 1856 in a64be58
Concretely, maybe this line can be rewritten? If using
T::class
can be avoided, there's no need for the function to be reified, thus allowing it to be used in non-inline generic functions.kmongo/kmongo-coroutine-core/src/main/kotlin/org/litote/kmongo/coroutine/CoroutineCollection.kt
Line 1859 in a64be58
The
save
function has, I believe, similar behavior if the involved class has an _id property, without it being reified.kmongo/kmongo-coroutine-core/src/main/kotlin/org/litote/kmongo/coroutine/CoroutineCollection.kt
Line 1262 in a64be58
My use case is as follows: we are building a internal library where we want to write a class that handles certain operations with a MongoDB database, but the concrete type can vary between different usages of the library. It is impossible to write this class using inline functions and reified generics, so we must use non-reified functions.
The text was updated successfully, but these errors were encountered: