bbatsov/rubocop — pull request #1456 by jcarbo (2014-11-23 04:29:23+00:00)
Title: Fix SymbolProc autocorrect with multiple offenses

When there were multiple offenses for the SymbolProc cop (e.g.
`coll.map { |s| s.upcase }.map { |s| s.downcase }`) the cop would
raise an error: `Parser::Source::Rewriter detected clobbering`.

Digging into recent commits I found some inspiration from
@jonas054 (#569). This commit changes the autocorrect for the
SymbolProc cop to be a little more precise in determining what to
correct. There's a new spec that I wrote that fails on master and
passes on this branch.