elseifpattern.codepoints[pp+1]==0x2dandpattern.codepoints[pp+2]andpattern.codepoints[pp+2]~=0x5dthen-- '-' followed by another char (not ']'), it's a range
fori=c,pattern.codepoints[pp+2]do
cs[i]=1
end
pp=pp+3
elseifnotcthen-- Should never get here, but Just In Case...
error('Missing close-bracket',3)
else
cs[c]=1
pp=pp+1
end
first=false
end
localret
ifnotcsrefs[2]then
ifnotinvertthen
-- If there's only the one charset table, we can use it directly