This pull request updates bat's tab expansion preprocessing function to use bat's vscreen::EscapeSequenceOffsetsIterator instead of console::AnsiCodeIterator.
Benchmarks
When running against a file with no tabs, there are no observable differences:
And when running against a file[^1] with 34443 tab characters, the difference is negligible:
However, it did trim a little over 16 KiB off the file size:
This pull request updates
bat
's tab expansion preprocessing function to usebat
'svscreen::EscapeSequenceOffsetsIterator
instead ofconsole::AnsiCodeIterator
.Benchmarks
When running against a file with no tabs, there are no observable differences:
And when running against a file[^1] with 34443 tab characters, the difference is negligible:
However, it did trim a little over 16 KiB off the file size:
[^1]: Command to create the file:
file fd --glob '*.rs' --exec-batch sh -c 'cat "$@" > lots-of.rs' {} && sed -i "s/ /\t/g" lots-of.rs