Skip to content

Commit acf4a19

Browse files
committed
\0 was not supported until 5.3
1 parent 3e08b36 commit acf4a19

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

primitives/dummy.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ local rep = string.rep
7171
local sub = string.sub
7272
local upper = string.upper
7373

74-
local utf8charpattern = '[\0-\127\194-\244][\128-\191]*'
74+
local utf8charpattern = '[%z\1-\127\194-\244][\128-\191]*'
7575

7676
local function utf8symbollen(byte)
7777
return not byte and 0 or (byte < 0x80 and 1) or (byte >= 0xF0 and 4) or (byte >= 0xE0 and 3) or (byte >= 0xC0 and 2) or 1

0 commit comments

Comments
 (0)