nlprule icon indicating copy to clipboard operation
nlprule copied to clipboard

Quality of the core

Open bminixhofer opened this issue 3 years ago • 2 comments

Currently the core is still largely in the state it was during prototyping. While abstractions are good and the code is clean documentation is missing in the internals.

So the key issue is:

  • [ ] Improving documentation of the internals.

Besides that, there are some cleanups needed such as:

  • [ ] Thinking about the distinction between byte and char indices and when should be converted between them (#21)
  • [ ] Better error messages for wrong binaries (#20)
  • [ ] Profile & reduce allocations (use more iterators...) (related #28)
  • [ ] Check opportunities to use Cow<str>
  • [ ] derive(Clone) all the (public) things.
  • [ ] Replace to_string with to_owned when converting from &str to String.
  • [ ] Making rayon optional behind a feature flag.

bminixhofer avatar Feb 26 '21 09:02 bminixhofer

Adding to the list of nice to haves:

  • avoid hindrance of cloning - current the regex engine used is not clone
  • provide more iterators and avoid allocations
  • use Cow<&str> where feasible

drahnr avatar Mar 02 '21 13:03 drahnr

Thanks, I added them to the list along with some other things.

bminixhofer avatar Mar 05 '21 11:03 bminixhofer