You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This means that foo cannot return the iterator sadly because of the use of let_gen_using, which leaks the shelf value which is owned by the foo function.
The whole reason I need to use the producer pattern is because gen!() doesn't accept a type argument (which is needed because of the dyn); would it be possible to have it allow a field that specifies what type the Rust compiler should know the generator results to be?
The text was updated successfully, but these errors were encountered:
Hi there,
I am wanting to have a generator that will yield values that are an
Rc<dyn T>
. Currently I have to do it like so:This means that foo cannot return the iterator sadly because of the use of
let_gen_using
, which leaks theshelf
value which is owned by thefoo
function.The whole reason I need to use the producer pattern is because
gen!()
doesn't accept a type argument (which is needed because of thedyn
); would it be possible to have it allow a field that specifies what type the Rust compiler should know the generator results to be?The text was updated successfully, but these errors were encountered: