class ActionDispatch::Routing::Mapper::Mapping
def verify_regexp_requirements(requirements, wildcard_options)
def verify_regexp_requirements(requirements, wildcard_options) requirements.each do |requirement, regex| next unless regex.is_a? Regexp if ANCHOR_CHARACTERS_REGEX.match?(regex.source) raise ArgumentError, "Regexp anchor characters are not allowed in routing requirements: #{requirement.inspect}" end if regex.multiline? next if wildcard_options.key?(requirement) raise ArgumentError, "Regexp multiline option is not allowed in routing requirements: #{regex.inspect}" end end end