Fix for KT-15575: VerifyError: Bad type on operand stack

#KT-15575 Fixed
This commit is contained in:
Mikhael Bogdanov
2017-01-09 17:50:11 +01:00
parent a3f6fbe0c1
commit 2931c316a3
14 changed files with 123 additions and 4 deletions
@@ -0,0 +1,9 @@
fun box(): String {
val array = arrayOf(doubleArrayOf(-1.0))
for (node in array) {
node[0] += 1.0
}
if (array[0][0] != 0.0) return "fail ${array[0][0]}"
return "OK"
}
@@ -0,0 +1,13 @@
fun box(): String {
val a = Array(2) { DoubleArray(3) }
for (i in 1..1) {
for (j in 0..2) {
a[i][j] += a[i - 1][j]
}
}
if (a[0][0] != 0.0) return "fail ${a[0][0]}"
return "OK"
}
@@ -0,0 +1,9 @@
fun box(): String {
val transform = transform(Array(1) { BooleanArray(1) })
if (!transform[0][0]) return "OK"
return "fail"
}
fun transform(screen: Array<BooleanArray>) = Array(1) { x ->
screen[x]
}
@@ -0,0 +1,4 @@
@kotlin.Metadata
public final class Kt15560Kt {
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
}
@@ -0,0 +1,4 @@
@kotlin.Metadata
public final class Kt15568Kt {
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
}
@@ -0,0 +1,5 @@
@kotlin.Metadata
public final class Kt15575Kt {
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
public final static @org.jetbrains.annotations.NotNull method transform(@org.jetbrains.annotations.NotNull p0: boolean[][]): boolean[][]
}