From e3b58d0c993aa4be16214ce52aea5952a9e5f877 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Thu, 13 Oct 2011 20:50:58 +0000 Subject: Adjustment to @switch. Don't require a tableswitch if the matcher elected not to emit one because there were so few cases. No review. --- test/files/pos/switch-small.scala | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 test/files/pos/switch-small.scala (limited to 'test/files') diff --git a/test/files/pos/switch-small.scala b/test/files/pos/switch-small.scala new file mode 100644 index 0000000000..9de9ca028e --- /dev/null +++ b/test/files/pos/switch-small.scala @@ -0,0 +1,8 @@ +import annotation._ + +object Test { + def f(x: Int) = (x: @switch) match { + case 1 => 1 + case _ => 2 + } +} -- cgit v1.2.3