Use proper descriptor for (generic) property assignment.

Insert IMPLICIT_INTEGER_COERCION only if Int is coerced to an integer type.
This commit is contained in:
Dmitry Petrov
2017-03-02 14:24:39 +03:00
parent 97fbbc74e6
commit f636ab21f8
5 changed files with 75 additions and 6 deletions
@@ -0,0 +1,16 @@
interface CPointed
inline fun <reified T : CPointed> CPointed.reinterpret(): T = TODO()
class CInt32VarX<T> : CPointed
typealias CInt32Var = CInt32VarX<Int>
var <T_INT : Int> CInt32VarX<T_INT>.value: T_INT
get() = TODO()
set(value) {}
class IdType(val value: Int) : CPointed
fun foo(value: IdType, cv: CInt32Var) {
cv.value = value.value
}