# File lib/facet/string/last%3D.rb, line 13 def last=(str, separator=$/) separator = /\n+/ if separator == '' separator = /\s+/ unless separator separator = Regexp.new( Regexp.escape( separator ) ) if String === separator i = self.rindex(separator) return nil unless i self[$~.end(0)..-1] = str end