blob: c45f16ab86bbbf90fbc04ace4e81daf8c5098b51 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
local function split(inputstr, sep)
if sep == nil then
sep = "%s"
end
local t = {}
for str in string.gmatch(inputstr, "([^"..sep.."]+)") do
table.insert(t, str)
end
return t
end
return { split = split }
|