Re: [VOTE] True Async RFC 1.6
| From: | Edmond Dantes | Date: | Sun, 23 Nov 2025 19:27:51 +0000 |
| Subject: | Re: [VOTE] True Async RFC 1.6 | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-129418@lists.php.net to get a copy of this message | ||
Hello.
Bob Weinand shared an excellent idea about how Fiber can be used
together with coroutines without breaking backward compatibility.
It is enough to automatically assign a coroutine to a fiber, and then
the code inside the fiber will be normalized relative to the
Scheduler.
Fiber receives the same properties as a coroutine and can be used as a
stackful generator.
This change makes it possible not to block Fiber, but instead allow it
to work together with TrueAsync and be used in cases where stackful
generators are needed.
A Fiber blocks the execution of the coroutine from which it was
started, meaning its symmetric behavior is preserved.
Respect to Bob Weinand
---
Ed