in reply to How does one get all possible matches from regex?
Try Regexp::Exhaustive - Find all possible matches, including backtracked and overlapping, of a pattern against a string