function _M.split(str, split_char)
if str == nil or str == "" or split_char == nil then
return nil
end
local t = {}
for m in (str..split_char):gmatch("(.-)".. split_char) do
table.insert(t, m)
end
return t
end
lua string 分割字符串
最新推荐文章于 2024-02-22 08:59:07 发布