summaryrefslogtreecommitdiff
path: root/test/files/run/t5590.scala
diff options
context:
space:
mode:
authorAleksandar Prokopec <axel22@gmail.com>2012-05-04 13:47:05 +0200
committerAleksandar Prokopec <axel22@gmail.com>2012-05-04 13:47:05 +0200
commitb2c3f87c7b1b613495eb563d909f24e1e22369d1 (patch)
tree897c2dfa592cc353891af0a25762c68cc1cc49ab /test/files/run/t5590.scala
parentf146d5826fc335ee1ca9c285d69086a7475cb71e (diff)
downloadscala-b2c3f87c7b1b613495eb563d909f24e1e22369d1.tar.gz
scala-b2c3f87c7b1b613495eb563d909f24e1e22369d1.tar.bz2
scala-b2c3f87c7b1b613495eb563d909f24e1e22369d1.zip
Fix for si-5590.
Diffstat (limited to 'test/files/run/t5590.scala')
-rw-r--r--test/files/run/t5590.scala31
1 files changed, 31 insertions, 0 deletions
diff --git a/test/files/run/t5590.scala b/test/files/run/t5590.scala
new file mode 100644
index 0000000000..9c806e0b7d
--- /dev/null
+++ b/test/files/run/t5590.scala
@@ -0,0 +1,31 @@
+
+
+
+import java.io._
+import collection._
+
+
+
+object Test {
+
+ def check(obj: AnyRef) {
+ println(obj)
+
+ val bos = new ByteArrayOutputStream()
+ val out = new ObjectOutputStream(bos)
+ out.writeObject(obj)
+ val arr = bos.toByteArray()
+ val in = new ObjectInputStream(new ByteArrayInputStream(arr))
+ val deser = in.readObject()
+
+ println(deser)
+ }
+
+ def main(args: Array[String]) {
+ val lhm = mutable.LinkedHashMap("a" -> "a", "b" -> "b", "c" -> "c")
+ val lhs = mutable.LinkedHashSet("a", "b", "c", "d", "e")
+ check(lhm)
+ check(lhs)
+ }
+
+}