kpreid / yield-progress

Progress reporting and cooperative task yielding in Rust
Apache License 2.0
2 stars 0 forks source link

Use non-exhaustive structs for the callbacks #9

Closed kpreid closed 10 months ago

kpreid commented 10 months ago

To increase forwards/backwards compatibility, both callback functions should accept structs that can be extended with more fields in the future.

(The yielder function currently accepts no arguments but it should be given the Location as part of fixing #1.)

kpreid commented 10 months ago

Note: I thought this was going to be a breaking change, but I made it non-breaking by combining it with the addition of a builder and keeping the old constructor functions as wrappers.