module Roda::RodaPlugins::Base::RequestMethods

def consume(pattern)

path from PATH_INFO, and updates captures with any regex captures.
SCRIPT_NAME to include the matched path, removes the matched
match, returns false without changes. Otherwise, modifies
Attempts to match the pattern to the current path. If there is no
def consume(pattern)
  if matchdata = remaining_path.match(pattern)
    @remaining_path = matchdata.post_match
    captures = matchdata.captures
    captures = yield(*captures) if block_given?
    @captures.concat(captures)
  end
end