Add whitespace token to swift and update test to match

This commit is contained in:
nrayburn 2020-02-04 11:50:53 -06:00
parent d2577bf88c
commit fcc397a6f5
2 changed files with 44 additions and 38 deletions

View file

@ -69,6 +69,7 @@ export const language = <ILanguage>{
tokenizer: {
root: [
{ include: '@whitespace' },
{ include: '@comment' },
{ include: '@attribute' },
{ include: '@literal' },
@ -77,6 +78,11 @@ export const language = <ILanguage>{
{ include: '@symbol' },
],
whitespace: [
[/\s+/, 'white'],
[/"""/, 'string.quote', '@endDblDocString']
],
symbol: [
[/[{}()\[\]]/, '@brackets'],
[/[<>](?!@symbols)/, '@brackets'],