Implement 'when' transformations (flatten, introduce subject, eliminate subject)
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
when {
|
||||
n == 1 -> {
|
||||
res = "one"
|
||||
}
|
||||
n == 2 -> {
|
||||
res = "two"
|
||||
}
|
||||
else -> {
|
||||
res = "???"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user