Skip to content
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

Tracking issue for RFC 2033: Experimentally add coroutines to Rust #43122

Open
aturon opened this issue Jul 8, 2017 · 155 comments
Open

Tracking issue for RFC 2033: Experimentally add coroutines to Rust #43122

aturon opened this issue Jul 8, 2017 · 155 comments
Labels
A-coroutines Area: Coroutines B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-coroutines `#![feature(coroutines)]` S-tracking-design-concerns Status: There are blocking design concerns. T-lang Relevant to the language team, which will review and decide on the PR/issue.

Comments

@aturon
Copy link
Member

aturon commented Jul 8, 2017

RFC.

This is an experimental RFC, which means that we have enough confidence in the overall direction that we're willing to land an early implementation to gain experience. However, a complete RFC will be required before any stabilization.

This issue tracks the initial implementation.

related issues

@aturon aturon added B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. T-lang Relevant to the language team, which will review and decide on the PR/issue. labels Jul 8, 2017
@alexcrichton
Copy link
Member

cc #43076, an initial implementation

@alexcrichton alexcrichton mentioned this issue Jul 22, 2017
7 tasks
@mitranim
Copy link

Copied from #43076:


I'm using this branch for stream-heavy data processing. By streams I mean iterators with blocking FS calls. Because Generator is missing an Iterator or IntoIterator implementation, you must call your own wrapper. Zoxc kindly provided an example, but it's quite unergonomic. Consider:

Python:

def my_iter(iter):
    for value in iter:
        yield value

Rust with generators:

fn my_iter<A, I: Iterator<Item=A>>(iter: I) -> impl Iterator<Item=A> {
    gen_to_iter(move || {
        for value in iter {
            yield value;
        }
    })
}

Two extra steps: inner closure + wrapper, and, worse, you have to write the wrapper yourself. We should be able to do better.

TL:DR: There should be a built-in solution for GeneratorIterator.

@Mark-Simulacrum Mark-Simulacrum added the C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC label Jul 27, 2017
@silene
Copy link

silene commented Aug 21, 2017

I was a bit surprised that, during the RFC discussion, links to the C++ world seemed to reference documents dating back from 2015. There have been some progress since then. The latest draft TS for coroutines in C++ is n4680. I guess the content of that draft TS will be discussed again when the complete RFC for Rust's coroutines is worded, so here are some of the salient points.

First, it envisions coroutines in a way similar to what this experimental RFC proposes, that is, they are stackless state machines. A function is a coroutine if and only if its body contains the co_await keyword somewhere (or co_yield which is just syntactic sugar for co_await, or co_return). Any occurrence of co_await in the body marks a suspension point where control is returned to the caller.

The object passed to co_await should provide three methods. The first one tells the state machine whether the suspension should be skipped and the coroutine immediately resumed (kind of a degenerate case). The second method is executed before returning control to the caller; it is meant to be used for chaining asynchronous tasks, handling recursive calls, etc. The third method is executed once the coroutine is resumed, e.g. to construct the value returned by the co_await expression. When implementing most generators, these three methods would have trivial bodies, respectively { return false; }, {}, and {}.

Various customization mechanisms are also provided. They tell how to construct the object received by the caller, how to allocate the local variables of the state machine, what to do at the start of the coroutine (e.g. immediately suspend), what to do at the end, what do to in case of an unhandled exception, what to do with the value passed to co_yield or co_return (how yielded values are passed back to the caller is completely controlled by the code).

@alexcrichton alexcrichton added the A-coroutines Area: Coroutines label Aug 30, 2017
@arielb1
Copy link
Contributor

arielb1 commented Sep 20, 2017

One subtle point that came up is how we handle the partially-empty boxes created inside of box statements with respect to OIBITs/borrows.

For example, if we have something like:

fn foo(...) -> Foo<...> {}
fn bar(...) -> Bar<...> {}
box (foo(...), yield, bar(...))

Then at the yield point, the generator obviously contains a live Foo<...> for OIBIT and borrow purposes. It also contains a semi-empty Box<(Foo<...>, (), Bar<...>)>, and we have to decide whether we should have that mean that it is to be treated like it contains a Box, just the Foo<...>, or something else.

@masonk
Copy link

masonk commented Jan 7, 2018

I might be missing something in the RFC, but based on the definition of resume in the Generator struct, and the given examples, it looks like these generators don't have two way communication. Ideally this language construct would allow us to yield values out and resume values into the generator.

Here's an example of implementing the async/await pattern using coroutines in ES6. The generator yields Promises and the coroutine resumes the generator with the unwrapped value of a Promise each time the Promise completes. There is no way this pattern could have been implemented without the two-way communication.

Rust has a problem here because what's the type of resume? In the ES6 example, the generator always yields out some kind of Promise and is always resumed with the unwrapped value of the Promise. However the contained type changes on each line. In other words, first it yields a Promise<X> and is resumed with an X, and then it yields a Promise<Y> and is resumed with a Y. I can imagine various ways of declaring that this generator first yields a Wrapper<X> and then a Wrapper<Y>, and expects to be resumed with an X and then a Y, but I can't imagine how the compiler will prove that this is what happens when the code runs.

TL;DR:
yield value is the less interesting half. It has the potential to be a much more ergonomic way to build an Iterator, but nothing more.

let resumedValue = yield value; is the fun half. It's what turns on the unique flow control possibilities of coroutines.

(Here are some more very interesting ideas for how to use two-way coroutines.)

@mikeyhew
Copy link
Contributor

@arielb1

Then at the yield point, the generator obviously contains a live Foo<...> for OIBIT and borrow purposes. It also contains a semi-empty Box<(Foo<...>, (), Bar<...>)>, and we have to decide whether we should have that mean that it is to be treated like it contains a Box, just the Foo<...>, or something else.

I don't know what you mean by "OIBIT". But at the yield point, you do not have a Box<(Foo<...>, (), Bar<...>)> yet. You have a <Box<(Foo<...>, (), Bar<...>)> as Boxed>::Place and a Foo<...> that would need to be dropped if the generator were dropped before resuming.

@clarfonthey
Copy link
Contributor

Looking at the API, it doesn't seem very ergonomic/idiomatic that you have to check if resume returns Yielded or Complete every single iteration. What makes the most sense is two methods:

fn resume(&mut self) -> Option<Self::Yield>;
fn await_done(self) -> Self::Return;

Note that this would technically require adding an additional state to closure-based generators which holds the return value, instead of immediately returning it. This would make futures and iterators more ergonomic, though.

I also think that explicitly clarifying that dropping a Generator does not exhaust it, stopping it entirely. This makes sense if we view the generator as a channel: resume requests a value from the channel, await_done waits until the channel is closed and returns a final state, and drop simply closes the channel.

@janhohenheim
Copy link
Contributor

janhohenheim commented Feb 28, 2018

Has there been any progress regarding the generator -> iterator conversion? If not, is there any active discussion about it somewhere? It would be useful to link it.
@Nemikolh and @uHOOCCOOHu, I'm curious about why you disagree with @clarcharr's suggestion. Care to share your thoughts?

@phaux
Copy link

phaux commented Mar 2, 2018

Has there been any progress regarding the generator -> iterator conversion? If not, is there any active discussion about it somewhere?

https://internals.rust-lang.org/t/pre-rfc-generator-integration-with-for-loops/6625

@Flupp
Copy link

Flupp commented Mar 28, 2018

I was looking at the current Generator-API and immediately felt uneasy when I read

If Complete is returned then the generator has completely finished with the value provided. It is invalid for the generator to be resumed again.

Instead of relying on the programmer to not resume after completion, I would strongly prefer if this was ensured by the compiler. This is easily possible by using slightly different types:

pub enum GeneratorState<S, Y, R> {
    Yielded(S, Y),
    Complete(R),
}

pub trait Generator where Self: std::marker::Sized {
    type Yield;
    type Return;
    fn resume(self) -> GeneratorState<Self, Self::Yield, Self::Return>;
}

(see this rust playground for a small usage example)

The current API documentation also states:

This function may panic if it is called after the Complete variant has been returned previously. While generator literals in the language are guaranteed to panic on resuming after Complete, this is not guaranteed for all implementations of the Generator trait.

So you might not immediately notice a resume-after-completion at runtime even when it actually occurs. A panic on resume-after-completion needs additional checks to be performed by resume, which would not be necessary with the above idea.

In fact, the same idea was already brought up in a different context, however, the focus of this discussion was not on type safety.

I assume there are good reasons for the current API. Nevertheless I think it is worth (re)considering the above idea to prevent resume-after-completion. This protects the programmer from a class of mistakes similar to use-after-free, which is already successfully prevented by rust.

@Nemo157
Copy link
Member

Nemo157 commented Mar 28, 2018

I too would have preferred a similar construction for the compile time safety. Unfortunately, that construction doesn't work with immovable generators, once they have been resumed they can't ever be passed by value. I can't think of a way to encode that constraint in a similar way for pinned references, it seems you need some kind of affine reference that you can pass in and recieve back in the GeneratorState::Yielded variant rather than the current lifetime scoped Pin reference.

@clarfonthey
Copy link
Contributor

A resume/await_done version seems much more ergonomic than moving the generator every time resume is called. And plus, this would prevent all of @withoutboats' work on pinning from actually being applied.

@rpjohnst
Copy link
Contributor

Note that Iterator has a similar constraint- it's not really a big deal, it doesn't affect safety, and the vast majority of users of the trait don't even have to worry about it.

@haudan
Copy link

haudan commented Apr 5, 2018

Question regarding the current experimental implementation: Can the yield and return types of generators (move-like syntax) be annotated? I would like to do the following:

use std::hash::Hash;

// Somehow add annotations so that `generator` implements
// `Generator<Yield = Box<Hash>, Return = ()>`.
// As of now, `Box<i32>` gets deduced for the Yield type.
let mut generator = || {
    yield Box::new(123i32);
    yield Box::new("hello");
};

@Nemo157
Copy link
Member

Nemo157 commented Apr 5, 2018

I was hopeful that let mut generator: impl Generator<Yield = Box<Debug>> = || { ... }; might allow this, but testing with

fn foo() -> impl Generator<Yield = Box<Debug + 'static>> {
    || {
        yield Box::new(123i32);
        yield Box::new("hello");
    }
}

it seems the associated types of the return value aren't used to infer the types for the yield expression; this could be different once let _: impl Trait is implemented, but I wouldn't expect it to be.

(Note that Hash can't be used as a trait object because its methods have generic type parameters which must go through monomorphization).

One terrible way to do this is to place an unreachable yield at the start of the generator declaring its yield and return types, e.g.:

let mut generator = || {
    if false { yield { return () } as Box<Debug> };
    yield Box::new(123i32);
    yield Box::new("hello");
};

EDIT: The more I look at yield { return () } as Box<Debug> the more I wonder how long till Cthulu truly owns me.

@haudan
Copy link

haudan commented Apr 5, 2018

Yeah, I was hoping as well impl Trait would do the trick, but couldn't get it to work either. Your if false { yield { return () } as Box<Debug> }; hack does indeed work, though after seeing that, I don't think I will be able to sleep for tonight.

I guess the only way is to introduce more syntax to annotate the types?

@Diggsey
Copy link
Contributor

Diggsey commented Apr 5, 2018

Will the Generator::resume() method be changed to use Pin<Self> and be safe, or is the idea to add a new SafeGenerator trait?

@Nemo157
Copy link
Member

Nemo157 commented Apr 7, 2018

I assumed that it would be changed, and I happened to be looking at the Pin RFC just now and noticed that it agrees, but it is blocked on object safety of arbitrary self types (which is currently an open RFC):

Once the arbitrary_self_types feature becomes object safe, we will make three changes to the generator API:

  1. We will change the resume method to take self by self: Pin<Self> instead of &mut self.
  2. We will implement !Unpin for the anonymous type of an immovable generator.
  3. We will make it safe to define an immovable generator.

The third point has actually happened already, but it doesn't help much since that required making Generator::resume unsafe.

@TheApproach
Copy link

@NobodyXu ah yes that makes perfect sense of course. I suppose the hope was that the Rust internals had some magic type wrangling to hide what my mind wants to think of as "forwarding null". I see that would not be the case.

Per resetting, that does make sense as well. Does that then imply that, when pure, @zesterer 's UnsafeCoroutine could be both trivial and safe?

Per upstream handling of safety, very nice to hear that.
From the sound of it FusedCoroutine would achieve what I was intending. thx

@NobodyXu
Copy link
Contributor

Per resetting, that does make sense as well. Does that then imply that, when pure, @zesterer 's UnsafeCoroutine could be both trivial and safe?

I think adding a new unsafe method is definitely doable and achievable, though ideally compiler should optimize out the panic landing code.

@Kixunil
Copy link
Contributor

Kixunil commented Jun 24, 2024

Does that then imply that, when pure, @zesterer 's UnsafeCoroutine could be both trivial and safe?

The reason for unsafe is actually Rust's moves. If you want to yield a network connection from a coroutine you can only do that once, so you either have to keep track of it at runtime or compile time. Runtime is slower and the compiler currently can't check it without introducing other costs (e.g. moving stuff around a lot), so only unsafe remains for performance-critical things.

There are tricks to deal with the unsafety though. The code is generated by the compiler, so the implementation doesn't need unsafe and calling it us usually done by some kind of executor which can be an easy place to audit unsafe. Further if we get &move references (AKA stack box - basically Box that has a lifetime because it's backed by stack; main feature being the ability to move out of it without runtime checks) we can design a safe wrapper with fn resume(&move self) -> CoroutineState<(Y, &move Self), R> which enforces correctness with tiny additional cost (having to move the pointer out). It should still be cheaper overall than forcing all coroutines to handle the state because it doesn't multiply over multiple layers of coroutines (this may be more visible in async code where people call async functions from async functions, each call creating an additonal layer with all the panic handling).

@NobodyXu the compiler can't optimize it across dynamic dispatch but a special trait can. I'm not suggesting that the cost of dynamic dispatch is small enough for this to matter, just stating the fact.

@NobodyXu
Copy link
Contributor

fn resume(&move self) -> CoroutineState<(Y, &move Self), R>

I wish Future::poll also uses &move self to avoid panic landing.

the compiler can't optimize it across dynamic dispatch but a special trait can.

That's true, adding an unsafe method or use &mut self could avoid the panic overhead.

Or maybe using a .fused() could avoid these panic overhead, at the cost of using Option<C> in layout and one additional if, it's definitely cheaper than panic.

@Kixunil
Copy link
Contributor

Kixunil commented Jul 15, 2024

@NobodyXu note that I've since realized that &move self is unsound because of the pin requirement to run destructor before overwriting the value and you can leak &move T which would prevent running the destructor. What is actually needed is PartialMove<Pin<&mut Self>> where PartialMove is a smart pointer that calls a special method (I chose the name cancel) which drops the parts that can be moved out but keeps whatever cannot, so that the pinned destructor can still run.

Also I've found a way to return a zero-sized token instead of PartialMove<Pin<&mut Self>> so that the whole trait could be safe and zero-cost! It just needs a different signature. However I came up with all these things when designing a state machine that's neither Future nor Coroutine but it's sufficiently similar that the same ideas can be applied. It's just that I have to rewrite it in terms of Future to explain it. (I've already started writing down the previously mentioned things about Future just haven't finished.)

Or maybe using a .fused() could avoid these panic overhead, at the cost of using Option<C> in layout and one additional if, it's definitely cheaper than panic.

The performance cost is the same - it's one branch and one byte in memory. Less panics probably means smaller binary but hardly anyone cares about it.

GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this issue Aug 13, 2024
…joboet

Add `#[must_use]` attribute to `Coroutine` trait

[Coroutines tracking issue](rust-lang#43122)

Like closures (`FnOnce`, `AsyncFn`, etc.), coroutines are lazy and do nothing unless called (resumed). Closure traits like `FnOnce` have `#[must_use = "closures are lazy and do nothing unless called"]` to catch likely bugs for users of APIs that produce them. This PR adds such a `#[must_use]` attribute to `trait Coroutine`.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Aug 13, 2024
…joboet

Add `#[must_use]` attribute to `Coroutine` trait

[Coroutines tracking issue](rust-lang#43122)

Like closures (`FnOnce`, `AsyncFn`, etc.), coroutines are lazy and do nothing unless called (resumed). Closure traits like `FnOnce` have `#[must_use = "closures are lazy and do nothing unless called"]` to catch likely bugs for users of APIs that produce them. This PR adds such a `#[must_use]` attribute to `trait Coroutine`.
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Aug 14, 2024
Rollup merge of rust-lang#129034 - henryksloan:coroutine-must-use, r=joboet

Add `#[must_use]` attribute to `Coroutine` trait

[Coroutines tracking issue](rust-lang#43122)

Like closures (`FnOnce`, `AsyncFn`, etc.), coroutines are lazy and do nothing unless called (resumed). Closure traits like `FnOnce` have `#[must_use = "closures are lazy and do nothing unless called"]` to catch likely bugs for users of APIs that produce them. This PR adds such a `#[must_use]` attribute to `trait Coroutine`.
@jonatino

This comment has been minimized.

@fu5ha
Copy link
Contributor

fu5ha commented Sep 18, 2024

Hi @jonatino,

Your example program seemingly does not exhibit undefined behavior as written, since the implementation of the one instance of the coroutine carefully re-assigns player at each yield boundary. However, your implementation is certainly unsound, since it is possible to invoke undefined behavior by only changing the safe implementation code of the coroutine. The justification you've written for your unsafe lifetime extension is not valid; this is easily proven by holding on to a player reference past a yield boundary, which should be fine, and realizing that the reference is now pointing somewhere random on the stack where the player variable was last time the coroutine was resumed; thus it is invalid and you've invoked undefined behavior.

I do think coroutines can be useful in game development, in similar contexts but with a different implementation.

That said, I would suggest that you learn the full capabilities of the language as it exists today, as there are other mechanisms that you can use to accomplish the same goal in a different way without requiring the stabilization of any features.

@VVishion
Copy link

@jonatino #68923
I don't know why your problem shouldnt be a fit for Coroutines, except that the lifetimes aren't sorted, yet. To my knowledge there is no mechanism in stable which encapsulates a state machine that elegantly.

@Sherlock-Holo
Copy link

will Coroutine trait support GAT?

currently

let iter = #[coroutine]
    static || {
        let v = vec![1, 2, 3];

        for i in &v {
            yield i;
        }
    };

is not work because

yields a value referencing data owned by the current function

@dabrahams
Copy link

Consider supporting yield-once coroutines, which allow you to expose real references to ephemeral “parts,” like slices of arrays, not to mention completely synthetic parts that reference no persistent memory. Getting rid of proxy references would be a huge win for generic programming.

@fogti
Copy link
Contributor

fogti commented Feb 3, 2025

@dabrahams Could you give a more concrete example (e.g. pseudo-rust code)?, because I don't think Rust has an equivalent to Swift' Accessors, and I can't imagine a scenario where that might be useful (except perhaps as a "strict" subclass of futures)...

@dabrahams
Copy link

dabrahams commented Feb 3, 2025

@fogti IIUC that change, if you have a way to ensure the generator is resumed after yielding, would give Rust the equivalent of Swift accessors, the lack of which creates numerous ergonomic problems. I'll try to come up with an example using your feature.

Edit: having looked more closely, I think the closure literal syntax may not be compatible with this use case. My Rust-fu is too weak to write even passable Rust pseudocode for you, unfortunately. I'll ask someone I'm working with to see if they can help.

@RishabhRD
Copy link

RishabhRD commented Feb 4, 2025

@dabrahams can you confirm if this example works for the context:

Consider this (pseudo-)rust code where proxy references might be necessary without yield once coroutine:

pub struct MappedArray<In, Out, F, FInv>
where
    F: Fn(&In) -> Out,
    FInv: Fn(Out) -> In,
{
    pub data: Vec<In>,
    pub f: F,
    pub f_inv: FInv,
}

impl<In, Out, F, FInv> MappedArray<In, Out, F, FInv>
where
    F: Fn(&In) -> Out,
    FInv: Fn(Out) -> In,
{
    pub fn at_mut(&mut self, i: usize) -> yield_once &mut Out {
        let mut mapped_val = (self.f)(&self.data[i]);
        yield (&mut mapped_val); // assuming mapped_val would be mutated to desired value by caller
        self.data[i] = (self.f_inv)(mapped_val);
    }

    pub fn push(&mut self, e: Out) {
        self.data.push((self.f_inv)(e));
    }
}

fn main() {
    let mut arr = MappedArray {
        data: Vec::default(),
        f: |x| x + 1,
        f_inv: |x| x - 1,
    };
    arr.push(2);
    arr.at_mut(0) = 3;
}

In this example, the correctness totally depends on the fact that control must come back to coroutine (most probably after last use of yielded value). For providing similar at_mut method for this class without yield once coroutine, proxy references would be necessary. A very similar usecase can be yielding a slice of array.

With proposed syntax, I don't think we can yield a reference to support the above usecase, also I tried similar code and realized, it is not mandatory that control returns to coroutine after yielding at all.

@fogti
Copy link
Contributor

fogti commented Feb 4, 2025

for "control needs to return to coroutine after yielding" I think using callbacks/closures (e.g. as parameter to at_mut above) which gets passed the yielded values (or for yield once, just the value as-is) is usual, and I'm not sure what use case the above would enable which isn't possible using callbacks currently, and has "control needs to return to coroutine after yielding" behavior (e.g. as an opt-in option at the definition of the coroutine (here: at_mut))

@RishabhRD
Copy link

RishabhRD commented Feb 4, 2025

@fogti, while passing closures works in this context, it does impact the ergonomics of the API. It introduces unnecessary nesting on the calling side, which can be cumbersome. With coroutine syntax, callers can still think sequentially, making the code more readable and maintainable.

Furthermore, yielding references with coroutines will not lead to lifetime problems, as it is guaranteed that control returns to the coroutine, similar to the behavior when using closures. So, complex borrow checking might not be necessary.

If I am correct, improving ergonomics was one of the main reasons why modify and read accessors were introduced in Swift, as constantly passing closures can be cumbersome. @dabrahams can provide more insights on this.

@Kixunil
Copy link
Contributor

Kixunil commented Feb 4, 2025

@RishabhRD you might be onto something. If the call to "return reference" gets injected by the borrow checker after last use it could be a "reliable destructor". The problem is if you do it in a Future it cannot be guaranteed (this is a long and significnat problem that nobody was able to solve yet).

You're absolutely right that closure ergonomics is not great but in many cases it can be solved with a ref wrapper that has Drop impl. (mutex guard etc)

@dabrahams
Copy link

@RishabhRD looks good to me, with my limited Rust knowledge. For ensuring that control returns to a (non-yield-once) coroutine, you would still have to use a proxy, but maybe you could embed resumption into the destructor of the proxy.

@dabrahams
Copy link

dabrahams commented Feb 5, 2025

One thing to keep in mind about the proxy, and I think this applies to @Kixunil's ref wrapper too: if you rely on drop() for safety, you are broken because std::mem::forget() has been deemed safe. If you dig into this discussion (which seems unrelated until you expand it) you can see some details. Of course if you only rely on it for correctness and not safety you can just explicitly forbid the use of forget on these things in documentation.

@dabrahams
Copy link

Actually modify and read accessors were added to swift for efficiency reasons. Previously there were only get (return a value without mutating the receiver) and set (roughly taking a & in Rust terms, and mutating the receiver) accessors, which meant a read-modify-write would require an expensive copy.

@Kixunil
Copy link
Contributor

Kixunil commented Feb 5, 2025

if you rely on drop() for safety, you are broken because std::mem::forget() has been deemed safe

Right, if we could also forbid holding the yielded reference across await we could have the original scoped thread API, no need to create annoying and confusing scope closure. And perhaps if someone figures out how to make Future's drop reliable, holding it will be fine.

jhpratt added a commit to jhpratt/rust that referenced this issue Feb 15, 2025
…ine, r=scottmcm

re-export `FromCoroutine` from `core::iter`

tracking issue: rust-lang#43122
fixes: rust-lang#135686
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Feb 15, 2025
Rollup merge of rust-lang#135687 - joseluis:feat-reexport_from_coroutine, r=scottmcm

re-export `FromCoroutine` from `core::iter`

tracking issue: rust-lang#43122
fixes: rust-lang#135686
RalfJung pushed a commit to RalfJung/miri that referenced this issue Feb 16, 2025
…ottmcm

re-export `FromCoroutine` from `core::iter`

tracking issue: rust-lang/rust#43122
fixes: #135686
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-coroutines Area: Coroutines B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-coroutines `#![feature(coroutines)]` S-tracking-design-concerns Status: There are blocking design concerns. T-lang Relevant to the language team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests