Artifact faa57f08e9d2587d51b4d33f4f15872169522816b451332c10825eb760496fec:
- File 残局文料/lib/程语_月_基类_文_内置库_加多.lua — part of check-in [581a2aaf5d] at 2024-01-27 02:24:20 on branch trunk — (/ω\) (user: 顽雨沉风, size: 427) [annotate] [blame] [check-ins using]
function string:lstrip() return self:gsub("^%s+", "") end function string:rstrip() return self:gsub("%s+$", "") end function string:strip() return self:lstrip():rstrip() end function string:startswith(text) local size = text:len() if self:sub(1, size) == text then return self end end function string:endswith(text) if self:sub(-#text) == text then return self end end