-
Notifications
You must be signed in to change notification settings - Fork 110
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
Added map-like
and filter-like
to sets.
#1217
base: master
Are you sure you want to change the base?
Conversation
Thanks! These look like they'd work, but we have a few comments:
|
Mmph. Okay, fine. I'll yield on the -like parts.
|
Thanks for the feedback! I'll try to implement the changes you suggested. A quick question, with regard to point 2, were you saying that for list-sets If you're referring to Thanks, -Ethan |
Hmm. If we want to be efficient, for
For
We would then have:
There are (Even though we use |
That makes a lot of sense. I guess I just didn't think about the speed of a filter implemented by fold vs the JS version. Thanks for the help! |
Also if the JS implementations provided a significant speed up, I assume the original implementation of
would be faster than:
|
The reason why my suggestion for The issue with
is that it allocates
would allocate at most only That said, I didn't mean to say which one is better, as I don't know if it's worth getting rid of intermediate structures or not, compared to using raw JS functions. Probably worth asking @jpolitz. |
@ess476 I'm assuming this is no longer on your radar? |
This adds the features requested in #1179. It also fixes a spelling mistake in the in the sets testing code.