Skip to content

Commit 70a490c

Browse files
committed
Fix group vs function at eof
1 parent e6dbaf4 commit 70a490c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

CoffeeScript.sublime-syntax

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,8 @@ contexts:
203203
- function-body
204204
- function-parameter-list
205205
- function-assignment
206-
- match: (?=\S)
206+
# any non-whitespace char or end of file
207+
- match: \S|\Z
207208
fail: function
208209

209210
function-assignment:
@@ -246,7 +247,8 @@ contexts:
246247
- match: '[=-]>'
247248
scope: meta.function.coffee keyword.declaration.function.coffee
248249
pop: 1
249-
- match: (?=\S)
250+
# any non-whitespace char or end of file
251+
- match: \S|\Z
250252
fail: function
251253

252254
###[ FUNCTION CALLS ]#########################################################

0 commit comments

Comments
 (0)