Made tokenizer skip parsing process on plain-text files

This, along with the earlier rencache changes should resolve #64
This commit is contained in:
rxi 2020-05-14 10:08:12 +01:00
parent bcd1b3a081
commit 6525269386
1 changed files with 4 additions and 0 deletions

View File

@ -42,6 +42,10 @@ function tokenizer.tokenize(syntax, text, state)
local res = {}
local i = 1
if #syntax.patterns == 0 then
return { "normal", text }
end
while i <= #text do
-- continue trying to match the end pattern of a pair if we have a state set
if state then