class Regexp

def as_json(options = nil) # :nodoc:

:nodoc:
def as_json(options = nil) # :nodoc:
  to_s
end

def multiline?

Regexp.new(".", Regexp::MULTILINE).multiline? # => true
Regexp.new(".").multiline? # => false

(/./m).multiline? # => true
(/./).multiline? # => false

Returns +true+ if the regexp has the multiline flag set.
def multiline?
  options & MULTILINE == MULTILINE
end