Now that I've started inserting coroutines into my apps (
https://futureofcoding.slack.com/archives/C0120A3L30R/p1698818828191999) to make them more debuggable, I'm starting to find and plug gaps in error recovery:
• I have to be careful to check the results of coroutine operations, because the underlying coroutine might have thrown an error.
• Errors in Lua include a call stack, but errors within coroutines don't return the stack by default.
• If I create a higher-order helper to abstract away the coroutine munging just to smear a computation across frames, does that impact the quality of debug information in the call stack? (Answer: no it doesn't in Lua, but it wasn't obvious.)
• Call stacks returned by LÖVE aren't
quite as clean as plain Lua.