diff options
author | Dominik Gruntz <dominik.gruntz@fhnw.ch> | 2012-07-17 15:38:58 +0200 |
---|---|---|
committer | Dominik Gruntz <dominik.gruntz@fhnw.ch> | 2012-07-17 15:48:37 +0200 |
commit | 9c4b0d0402559921d4f36e9ebdd1af9a818fdde7 (patch) | |
tree | ba04a2af0e0c83b3a278e69d8efa9389f9031f99 /test/files/neg/t5856.scala | |
parent | bad93927836f302be3b973335a63bb5e69b2237c (diff) | |
download | scala-9c4b0d0402559921d4f36e9ebdd1af9a818fdde7.tar.gz scala-9c4b0d0402559921d4f36e9ebdd1af9a818fdde7.tar.bz2 scala-9c4b0d0402559921d4f36e9ebdd1af9a818fdde7.zip |
SI-5856 enables use of $this in string interpolation
This pull request fixes SI-5856. The scanner has been modified
to return the correct token if keywords appear in $-expressions.
The parser has been modified to issue an error and to only accept
$<identifier>, $this and $block.
Diffstat (limited to 'test/files/neg/t5856.scala')
-rw-r--r-- | test/files/neg/t5856.scala | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/files/neg/t5856.scala b/test/files/neg/t5856.scala new file mode 100644 index 0000000000..2ceee590af --- /dev/null +++ b/test/files/neg/t5856.scala @@ -0,0 +1,11 @@ +object Test { + val s1 = s"$null" + val s2 = s"$false" + val s3 = s"$true" + val s4 = s"$yield" + val s5 = s"$return" + val s6 = s"$new" + val s7 = s"$s1 $null $super" + val s8 = s"$super" + val s9 = s"$" +}
\ No newline at end of file |