Package trw
wraps around various text processing functions from the standard
Go library to allow for functional composition of operations, also minimising
memory consumption. Here is an example of usage.
The package is most useful in situations where a number of text rewriting operations is to be applied sequentially to a large input byte slice. For this scenario the package provides:
- Functional composition of the existing or user-defined operations that can later be applied all at once;
- Memory optimisation using various techniques to minimise (re)allocations.