The bytes, strings, and regexp packages provide functions for replacing text in strings and byte slices. These only operate on strings and byte slices that are in memory. I propose a new golang.org/x/text/replace package which implements golang.org/x/text/transform.Transformer's for replacing text. These would enable doing text replacements on io.Readers.
The
bytes
,strings
, andregexp
packages provide functions for replacing text in strings and byte slices. These only operate on strings and byte slices that are in memory. I propose a newgolang.org/x/text/replace
package which implementsgolang.org/x/text/transform.Transformer
's for replacing text. These would enable doing text replacements onio.Reader
s.prototype: https://github.com/icholy/replace
The text was updated successfully, but these errors were encountered: