Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add search/split iterators for Rust #79

Open
ashvardanian opened this issue Feb 7, 2024 · 3 comments
Open

Add search/split iterators for Rust #79

ashvardanian opened this issue Feb 7, 2024 · 3 comments
Labels
good first issue Good for newcomers rust

Comments

@ashvardanian
Copy link
Owner

In C++ we have special smart iterators for bulk search and split operations. They lazily report the matches, avoiding heap allocations for the array of match offsets.

For that, an arbitrary matcher (string / character / character set ; in normal / reverse order) is combined with search / split ranges. Similar functionality should be added in Rust.

@ashvardanian ashvardanian added cpp rust good first issue Good for newcomers and removed cpp labels Feb 7, 2024
@ashvardanian
Copy link
Owner Author

Assuming search and split operations are lazy by default on native strings, I’m wondering if there is a way to avoid reimplementing those operations and still benefit from SZ speeds.

@grouville
Copy link
Contributor

Would you be interested in me investigating this issue ? I can come up with a proposal as a draft PR too

@ashvardanian
Copy link
Owner Author

Yes, @grouville, that can be very useful, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers rust
Projects
None yet
Development

No branches or pull requests

2 participants