Message from JavaScript discussions
December 2018
— JS is in the dark ages still
What makes it complicated is doing so within the unchanged execution environment, dealing with the problems it brings
— It expects X, I do Y
— But, my Y appears as X, which is where the complexity lies
— They would run the same every time
— Unless you ran each with spawn
preceding it
— Generally all coroutines run deterministically until you determine their ready status based on a timer like a busy wait
— The event-loop is already synchroneous, so everything goes ordered already, there is a need for parallel things, but it's a rare/specific use-case
— When you busy wait, you are doing CPU cycle wasting and waste a random amount of cycles for every loop spin, and this is non-deterministic, causing coroutines to "skip" sometimes and run in a different order suddenly
— Busywait is non-sensical in the first place so I imagine it won't be a common problem
— HertzScript solves this case for both node and browser
— Again, only matters for spawned processes, right?