From 4d96a8ad0b7050303e0b841708ba452e708f6a35 Mon Sep 17 00:00:00 2001 From: Som Snytt Date: Tue, 16 Dec 2014 13:43:17 -0800 Subject: SI-5154 Parse leading literal brace in XML pattern Don't consume literal brace as Scala pattern. Previously, leading space would let the text parser `xText` handle it correctly instead. --- test/files/pos/t5154.scala | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 test/files/pos/t5154.scala (limited to 'test/files') diff --git a/test/files/pos/t5154.scala b/test/files/pos/t5154.scala new file mode 100644 index 0000000000..2629308f00 --- /dev/null +++ b/test/files/pos/t5154.scala @@ -0,0 +1,9 @@ + +trait Z { + // extra space made the pattern OK + def f = {{3}} match { case {{3}} => } + + // lack of space: error: illegal start of simple pattern + def g = {{3}} match { case {{3}} => } +} + -- cgit v1.2.3