diff --git a/compiler/testData/codegen/regressions/kt1733.kt b/compiler/testData/codegen/regressions/kt1733.kt new file mode 100644 index 00000000000..aae42e93065 --- /dev/null +++ b/compiler/testData/codegen/regressions/kt1733.kt @@ -0,0 +1,12 @@ +fun box(args) : String { + val map = java.util.TreeMap() + map["a"] = "1" + map["b"] = "2" + + var list = arrayList() + for (e in map) { + list += e.getKey() + } + + return if(list.size==2) "OK" else "fail" +} diff --git a/compiler/tests/org/jetbrains/jet/codegen/StdlibTest.java b/compiler/tests/org/jetbrains/jet/codegen/StdlibTest.java index ad64b9943c5..991e7c80a3b 100644 --- a/compiler/tests/org/jetbrains/jet/codegen/StdlibTest.java +++ b/compiler/tests/org/jetbrains/jet/codegen/StdlibTest.java @@ -344,4 +344,8 @@ public class StdlibTest extends CodegenTestCase { public void testUptoDownto() { blackBoxFile("uptoDownto.kt"); } + + public void test1733() { + blackBoxFile("regressions/kt1733.kt"); + } }