pathmap_replace (String)

         # File lib/rake.rb, line 118
    118:     def pathmap_replace(patterns, &block)
    119:       result = self
    120:       patterns.split(';').each do |pair|
    121:         pattern, replacement = pair.split(',')
    122:         pattern = Regexp.new(pattern)
    123:         if replacement == '*' && block_given?
    124:           result = result.sub(pattern, &block)
    125:         elsif replacement
    126:           result = result.sub(pattern, replacement)
    127:         else
    128:           result = result.sub(pattern, '')
    129:         end
    130:       end
    131:       result
    132:     end