red-blox / zap

A lightning fast networking solution for roblox.
https://zap.redblox.dev
MIT License
89 stars 14 forks source link

Add function returns with `YieldType::Future` or `YieldType::Yield` #125

Closed Ketasaja closed 1 month ago

Ketasaja commented 1 month ago

Another attempt of #124. Emit is now better when using YieldType::Future or YieldType::Yield, and no worse when not.

Assumes Future type exists in async_lib when async_type = "future".

There's no type when using Promises without TypeScript, this can probably change once the new solver releases, but it would be breaking.