Generate argument expression instead of constructor for inline classes

This commit is contained in:
Mikhail Zarechenskiy
2018-02-04 23:44:16 +03:00
parent 928a342ace
commit 2536eb4d45
6 changed files with 77 additions and 0 deletions
@@ -0,0 +1,10 @@
// !LANGUAGE: +InlineClasses
inline class Foo(val s: String) {
fun asResult(): String = s
}
fun box(): String {
val a = Foo("OK")
return a.asResult()
}