Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Commit

Permalink
Merge pull request #100 from Ingramz/wl-tags-off-by-one
Browse files Browse the repository at this point in the history
Fix insertion of newline characters to the end of lines
  • Loading branch information
Max Brunsfeld authored Sep 22, 2017
2 parents 48054da + facfc3d commit 9295b56
Show file tree
Hide file tree
Showing 9 changed files with 2,240 additions and 642 deletions.
2 changes: 1 addition & 1 deletion benchmark/benchmark.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ GrammarRegistry = require '../src/grammar-registry'
registry = new GrammarRegistry()
jsGrammar = registry.loadGrammarSync(path.resolve(__dirname, '..', 'spec', 'fixtures', 'javascript.json'))
jsGrammar.maxTokensPerLine = Infinity
cssGrammar = registry.loadGrammarSync(path.resolve(__dirname, '..', 'spec', 'fixtures', 'css.json'))
cssGrammar = registry.loadGrammarSync(path.resolve(__dirname, '..', 'spec', 'fixtures', 'css.cson'))
cssGrammar.maxTokensPerLine = Infinity

tokenize = (grammar, content, lineCount) ->
Expand Down
35 changes: 35 additions & 0 deletions spec/fixtures/captures-patterns.cson
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
'scopeName': 'abcabx'
'patterns': [
{
'match': 'a(.+)c'
'captures':
'1':
'patterns':[
{
'match': '[^c]+'
'name': 'b'
}
]
'name': 'abc'
},
{
'match': 'a(.+)x'
'captures':
'1':
'patterns':[
{
'match': '[^x]+'
'name': 'up-to-x-outer'
'captures':
'0':
'patterns':[
{
'match': '.+'
'name': 'up-to-x-inner'
}
]
}
]
'name': 'abx'
}
]
Loading

0 comments on commit 9295b56

Please sign in to comment.