fixed keyword that contains `-`

pull/2748/head
Avelino 7 years ago
parent 8bfec94690
commit 380fe86dd8

@ -27,6 +27,14 @@ testTokenization('clojure', [
{ startIndex: 8, type: 'string.clj'}, { startIndex: 8, type: 'string.clj'},
], ],
}, },
{
line: 'in-ns "user',
tokens: [
{ startIndex: 0, type: 'keyword.clj' },
{ startIndex: 5, type: 'white.clj' },
{ startIndex: 6, type: 'string.clj' },
],
},
], ],
// comments // comments

@ -44,9 +44,9 @@ export const language = <ILanguage>{
keywords: [ keywords: [
'ns', 'ns',
'ns-unmap', 'ns\-unmap',
'create-ns', 'create\-ns',
'in-ns', 'in\-ns',
'fn', 'fn',
'def', 'def',
'defn', 'defn',
@ -71,15 +71,15 @@ export const language = <ILanguage>{
'iterate', 'iterate',
'range', 'range',
'drop', 'drop',
'drop\\-while', 'drop\-while',
'take', 'take',
'take\\-while', 'take\-while',
'neg', 'neg',
'neg?', 'neg?',
'bound\\-fn', 'bound\-fn',
'if', 'if',
'if\\-not', 'if\-not',
'if\\-let', 'if\-let',
'case,', 'case,',
'contains', 'contains',
'conj', 'conj',
@ -97,13 +97,13 @@ export const language = <ILanguage>{
'contains?', 'contains?',
'cond', 'cond',
'condp', 'condp',
'cond\\-\\>', 'cond\-\>',
'cond\\-\\>\\>', 'cond\-\>\>',
'when', 'when',
'while', 'while',
'when\\-not', 'when\-not',
'when\\-let', 'when\-let',
'when\\-first', 'when\-first',
'do', 'do',
'future', 'future',
'comment', 'comment',
@ -114,7 +114,7 @@ export const language = <ILanguage>{
'type', 'type',
'meta', 'meta',
'var', 'var',
'as\\-\\>', 'as\-\>',
'reify', 'reify',
'deftype', 'deftype',
'defrecord', 'defrecord',
@ -123,7 +123,7 @@ export const language = <ILanguage>{
'extend-protocol', 'extend-protocol',
'extend-type', 'extend-type',
'specify', 'specify',
'specify\\!', 'specify\!',
'try', 'try',
'catch', 'catch',
'finally', 'finally',
@ -135,25 +135,25 @@ export const language = <ILanguage>{
'seq', 'seq',
'doseq', 'doseq',
'dotimes', 'dotimes',
'when\\-let', 'when\-let',
'if\\-let', 'if\-let',
'when\\-some', 'when\-some',
'if\\-some', 'if\-some',
'this\\-as', 'this\-as',
'defmethod', 'defmethod',
'testing', 'testing',
'deftest', 'deftest',
'are', 'are',
'use\\-fixtures', 'use\-fixtures',
'use', 'use',
'remove', 'remove',
'run', 'run',
'run\\*', 'run\*',
'fresh', 'fresh',
'alt!', 'alt!',
'alt!!', 'alt!!',
'go', 'go',
'go\\-loop', 'go\-loop',
'thread', 'thread',
], ],

Loading…
Cancel
Save