chipmunk icon indicating copy to clipboard operation
chipmunk copied to clipboard

Implementation for text_grep - Issue (Searcher (rustcore) #1715)

Open itsmesamster opened this issue 1 year ago • 1 comments

itsmesamster avatar Feb 18 '24 22:02 itsmesamster

@itsmesamster thanks for PR. I have a couple of comments in general:

  • do not mix async and stuff from std. I'm about threads, channels etc from std... If you need to spawn something it should be really motivated and we should use tokio to do it (because it's major framework for chipmunk)
  • try to keep away from Arc, Mutex etc... many use-cases can be resolved avoiding it.
  • make sure you do not post any into terminal... It's crate/lib - it should return status. We can post something only for debugging
  • please define Error enum for errors of your crate. Take a look to thiserror crate, which can be useful for string converting
  • please add some information about measurements...

DmitryAstafyev avatar Feb 19 '24 22:02 DmitryAstafyev

image

Some random measurements and proof that the count is correct as per ripgrep, depending on the case sensitivity flag.

itsmesamster avatar Feb 22 '24 19:02 itsmesamster