diff options
Diffstat (limited to 'search.lua')
-rw-r--r-- | search.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/search.lua b/search.lua index 37306f8..f7d4732 100644 --- a/search.lua +++ b/search.lua @@ -116,6 +116,8 @@ function find(s, pat, i, plain) return s:find(pat, i, plain) end +-- TODO: avoid the expensive reverse() operations +-- Particularly if we only care about literal matches, we don't need all of string.find function rfind(s, pat, i, plain) if s == nil then return end local rs = s:reverse() |