Conversation
hirrolot
left a comment
There was a problem hiding this comment.
This is a breaking change, right?
|
Yes, this is a breaking change. |
|
The only reason to make the change is to structure the code in the library with less hassle? In Rust, we normally expose the most generic function type to library users, which is |
|
While it's true that this change makes calling the continuation more restrictive, at the same time it makes writing the continuation a lot less restrictive. We lose ability to call continuation multiple times (that we didn't use anyway) but gain ability to move stuff into the closure, to set flags from inside it, etc. There really isn't any reason for the continuation to be
Not really, as said before: it's more permissive to call, but not to provide.
While this could of course be the case, this is highly unlikely. For this change to break something a user would need to be writing their own handlers (instead of using tools provided by this library) and calling the continuation multiple times ( |
This generally makes code a little bit nicer