Commit 86bf4d7
committed
Speed up spellchecking by ignoring whitespace-only lines
Whitespace only lines cannot have typos in them at all on account of
not containing any words. Nevertheless, codespell did not exit early
on them causing quite some overhead.
By special-casing empty and whitespace only, it is possible to reduce
the runtime from ~5.4s to ~5.0s on the corpus mentioned in #3419.1 parent 73b7b5e commit 86bf4d7
1 file changed
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
946 | 946 | | |
947 | 947 | | |
948 | 948 | | |
949 | | - | |
| 949 | + | |
| 950 | + | |
950 | 951 | | |
951 | 952 | | |
952 | 953 | | |
| |||
0 commit comments