-
Notifications
You must be signed in to change notification settings - Fork 177
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
Some simplifications #784
Some simplifications #784
Conversation
The second commit looks good. Thanks! I want to note for future reference, that it changes the order in which The first commit should be fine, but I hesitate to merge it, because it may have some subtle implications. I suggest replacing it with a comment explaining that |
I added a note in the CHANGES file, not sure if that's how you want to keep track of it. If not let me know and I can remove that part.
I'll make that change. How strongly should I encourage people to use It could be good to ask people to try an run their big project on the yield-is-pause variant and see if anything breaks. A bit like the opam switch thing on the compiler variants. |
9eda7ee
to
2b67f2d
Compare
2b67f2d
to
79544a7
Compare
I just thought of one possible way to keep a fully backwards-compatible semantics for parallel iterators: provide an alternatvie to
I don't know if it is worth adding a new function that behaves so similarly to IMO it's not worth it. (IMO we should randomly select either of the |
Thanks!
[On adding a new function] I agree.
I usually write/rewrite the changelog right before release, so this is fine :)
It would probably be too noisy to attach a deprecation annotation to it, so I think the way you have the docs recommend |
Two relatively simple modifications. (Albeit one is simple but not trivial.)
The first commit implements
Lwt_main.yield
as a call toLwt.pause
and removes all the support code associated with the previous implementation. This is not trivial and may have subtle effects on the scheduling performed inLwt_main.run
.The second commit simply avoids some
List.rev
calls when traversing lists (iter_p
,iteri_p
, etc.).