commit | 5cf7afbd2fc648563b5b0df56a23cae8f92f33f3 | [log] [tgz] |
---|---|---|
author | Dave Borowitz <dborowitz@google.com> | Thu Apr 04 11:41:32 2013 -0700 |
committer | Dave Borowitz <dborowitz@google.com> | Thu Apr 04 16:48:22 2013 -0700 |
tree | 06a4d224ec15322f97c0b4226a1ac6a29ff81526 | |
parent | 6e3cd392cccf809ca7346b6c54fba41fee99fee6 [diff] |
Replace a list of RegexFindReplaces in a single pass Replacing in multiple passes, especially if each different RegexFindReplaces come from different sources (e.g. users), can lead to some confusing and likely dangerous behavior. Instead, replace in a single pass by unioning patterns together and re-exec'ing the patterns to see which one matched. Change-Id: If218c9e47b3aca8ff665f1da844279aba3cbcc35