Fixing splats after newlines - #754.

This commit is contained in:
Sam Stephenson
2010-10-10 11:34:22 -05:00
parent f6ca5d814c
commit 20a07c174c
6 changed files with 36 additions and 23 deletions

View File

@@ -114,3 +114,12 @@ list = [a = 0, nums..., b = 4]
ok a is 0
ok b is 4
ok list.join(' ') is '0 1 2 3 4'
# Splat on a line by itself is invalid.
failed = true
try
CoffeeScript.compile "x 'a'\n...\n"
failed = false
catch err
ok failed