Re: [PHP-DEV] [RFC] Fiber support (again)

2018-02-09 Thread Niklas Keller
2018-02-09 21:53 GMT+01:00 Björn Larsson : > Regarding these potential new keywords await & async. > Any need to look into how Hacklang uses these keywords? > Could there be portability aspects on the functionality in > itself? No, there's no need to look at Hacklang

Re: [PHP-DEV] [RFC] Fiber support (again)

2018-02-09 Thread Björn Larsson
Den 2018-02-09 kl. 12:48, skrev Niklas Keller: We have started building a PoC library on top of Fibers, see https://github.com/amphp/green-thread/blob/7bd3470e7986169372d5e9c39500f3652091b512/src/functions.php . We'd like to avoid the additional `await()` function and rather directly couple

Re: [PHP-DEV] [RFC] Fiber support (again)

2018-02-09 Thread Niklas Keller
> > > The language should offer a sane API, not the absolute minimum required > to > > work for these things. > > The Ruby's Fiber do offer a live? method but does not have a getStatus > method. > The Lua's coroutine only offer a status method. > > So do we really need to offer three additional

Re: [PHP-DEV] [RFC] Fiber support (again)

2018-02-09 Thread S.A.N
This has already been discussed in github Fiber::resume() https://github.com/fiberphp/fiber-ext/issues/7 Fiber::throw() https://github.com/fiberphp/fiber-ext/issues/6 Keywords - async/await https://github.com/fiberphp/fiber-ext/issues/10 I believe that current API is normal for the Pecl ext,