lukeed/tidyPublic

perf: shared lines, faster scans

line, softline, hardline, literalline and breakParent are shared docs,
as in Prettier. The lexer finds the end of plain text with memchr3 and
looks for a NUL once, and width counts runs of printable ASCII at once.
Pages on one thread: 67 to 64 ms.
LELuke Edwards authored
271c770Patch
Parent17fae60
4 files changed+98-36
StackedSplit
crates/tidyrs/src/doc/mod.rs+36 −16
crates/tidyrs/src/doc/width.rs+40 −18
crates/tidyrs/src/html/lexer.rs+12 −2
crates/tidyrs/src/html/mod.rs+10 −0