summaryrefslogtreecommitdiff
path: root/test/files/instrumented
diff options
context:
space:
mode:
authorJason Zaugg <jzaugg@gmail.com>2012-11-04 14:17:25 +0100
committerJason Zaugg <jzaugg@gmail.com>2012-11-04 14:17:25 +0100
commit8265175ecc42293997d59049f430396c77a2b891 (patch)
treea24c7820bee892eb802d5c691e1e57a62ff43bb4 /test/files/instrumented
parentdad886659faca4fba2d4937c9bc6780591b02c27 (diff)
downloadscala-8265175ecc42293997d59049f430396c77a2b891.tar.gz
scala-8265175ecc42293997d59049f430396c77a2b891.tar.bz2
scala-8265175ecc42293997d59049f430396c77a2b891.zip
Expand optimization of Array(e1, ..., en) to primitive arrays.
Diffstat (limited to 'test/files/instrumented')
-rw-r--r--test/files/instrumented/t6611.scala24
1 files changed, 23 insertions, 1 deletions
diff --git a/test/files/instrumented/t6611.scala b/test/files/instrumented/t6611.scala
index 821d5f3fbf..4c52f8a5ef 100644
--- a/test/files/instrumented/t6611.scala
+++ b/test/files/instrumented/t6611.scala
@@ -5,7 +5,29 @@ object Test {
startProfiling()
// tests optimization in Cleanup for varargs reference arrays
- val a = Array("")
+ Array("")
+
+
+ Array(true)
+ Array(true, false)
+ Array(1: Byte)
+ Array(1: Byte, 2: Byte)
+ Array(1: Short)
+ Array(1: Short, 2: Short)
+ Array(1)
+ Array(1, 2)
+ Array(1L)
+ Array(1L, 2L)
+ Array(1d)
+ Array(1d, 2d)
+ Array(1f)
+ Array(1f, 2f)
+
+ /* Not currently optimized:
+ Array[Int](1, 2) etc
+ Array(())
+ Array((), ())
+ */
stopProfiling()
printStatistics()