Skip to content

Commit fe0298c

Browse files
committed
don't include object keys
1 parent b6840cf commit fe0298c

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

lib/coffeescript/lexer.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/lexer.coffee

+1-1
Original file line numberDiff line numberDiff line change
@@ -1293,7 +1293,7 @@ POSSIBLY_DIVISION = /// ^ /=?\s ///
12931293
# Other regexes.
12941294
HERECOMMENT_ILLEGAL = /\*\//
12951295
1296-
LINE_CONTINUER = /// ^ \s* (?: , | \??\.(?![.\d]) | \??:: | and#{' '} | or#{' '} | && | \|\| ) ///
1296+
LINE_CONTINUER = /// ^ \s* (?: , | \??\.(?![.\d]) | \??:: | and\s+(?!:)\S | or\s+(?!:)\S | && | \|\| ) ///
12971297
12981298
STRING_INVALID_ESCAPE = ///
12991299
( (?:^|[^\\]) (?:\\\\)* ) # Make sure the escape isn’t escaped.

test/formatting.coffee

+10
Original file line numberDiff line numberDiff line change
@@ -483,3 +483,13 @@ test "logical and/or should continue lines", ->
483483

484484
ok 'abc'
485485
|| 123
486+
487+
a =
488+
and : 'b'
489+
or : 'a'
490+
ok 'a' is a.or
491+
492+
b =
493+
or : 'b'
494+
and : 'a'
495+
ok 'a' is b.and

0 commit comments

Comments
 (0)