Support destructuring declarations in scripts and REPL

#KT-5620 In Progress
 #KT-15810 In Progress
This commit is contained in:
Mikhail Zarechenskiy
2017-05-24 16:32:33 +03:00
parent 0e31c14a86
commit 400ecd5e13
21 changed files with 333 additions and 46 deletions
@@ -0,0 +1,16 @@
val (a1, a2) = A()
val (b1: Int, b2: Int) = <!COMPONENT_FUNCTION_RETURN_TYPE_MISMATCH!>A()<!>
val (c1) = <!UNRESOLVED_REFERENCE!>unresolved<!>
<!WRONG_MODIFIER_TARGET!>private<!> val (d1) = A()
val (e1, _) = A()
a1
a2
e1
class A {
operator fun component1() = 1
operator fun component2() = ""
}