feat: refactor sentence and word analysis to use counts instead of collections
Rewrite `get_sentences` to return a `usize` count instead of `Vec<&str>`, removing the trailing-dot cleanup logic. Replace `get_words` and `get_capitalized_words` with a single `get_words` function that mutates output counters for total words, capitalized words, and forbidden words, iterating directly over the content. Add release profile optimizations with thin LTO and abort-on-panic in Cargo.toml.
This commit is contained in:
@@ -5,3 +5,7 @@ edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
rayon = "1.10.0"
|
||||
|
||||
[profile.release]
|
||||
lto = "thin"
|
||||
panic = "abort"
|
||||
|
||||
Reference in New Issue
Block a user