1
0
mirror of https://github.com/alecthomas/chroma.git synced 2025-07-17 01:22:22 +02:00

Invert default "ensure newline" behaviour so that it is opt-in.

See #47.
This commit is contained in:
Alec Thomas
2017-09-30 14:40:39 +10:00
parent 573c1d157d
commit ce3d6bf527
6 changed files with 7 additions and 6 deletions

View File

@ -44,7 +44,7 @@ func TestInclude(t *testing.T) {
}
func TestCombine(t *testing.T) {
l := MustNewLexer(&Config{DontEnsureNL: true}, Rules{
l := MustNewLexer(nil, Rules{
"root": {{`hello`, String, Combined("world", "bye", "space")}},
"world": {{`world`, Name, nil}},
"bye": {{`bye`, Name, nil}},