pluots / zspell

A spellchecking library and executable written in Rust
Other
45 stars 4 forks source link

Refactor `Source` to store the specific matched pattern #76

Closed tgross35 closed 1 year ago

tgross35 commented 1 year ago

Save the index of the relevant AfxRulePattern with the Arc<Affix> in Source::Affix. This allows us to retrieve morph rules from that specific pattern, rather than returning all rules in the Affix.

Fixes #73

codecov[bot] commented 1 year ago

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (b340f33) 74.73% compared to head (47fe1d5) 74.88%. Report is 2 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #76 +/- ## ========================================== + Coverage 74.73% 74.88% +0.14% ========================================== Files 24 24 Lines 3218 3237 +19 ========================================== + Hits 2405 2424 +19 Misses 813 813 ``` | [Files](https://app.codecov.io/gh/pluots/zspell/pull/76?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pluots) | Coverage Δ | | |---|---|---| | [zspell/src/dict/helpers.rs](https://app.codecov.io/gh/pluots/zspell/pull/76?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pluots#diff-enNwZWxsL3NyYy9kaWN0L2hlbHBlcnMucnM=) | `100.00% <100.00%> (ø)` | | | [zspell/src/dict/types.rs](https://app.codecov.io/gh/pluots/zspell/pull/76?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pluots#diff-enNwZWxsL3NyYy9kaWN0L3R5cGVzLnJz) | `71.73% <90.90%> (+1.28%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.