Skip to content

Comment on You can't cancel a JavaScript promise (except sometimes you can)

Comments

I soft of feel like every five years someone comes along and tries to re-invent cancellable threads and immediately arrives back at the same conclusion: the problem of what it means to "cancel" a thread is so domain-specific that you never save anything trying to "support" it in your threading framework; you try and save people the effort of doing something ad-hoc to simulate cancellation and build something at least as complicated as what they would build ad-hoc, because thread cancellation is too intimately tied to the problem domain the threads are operating on to generalize it.

But what if we add another layer of indirection.

The fundamental theorem of software engineering.

https://en.wikipedia.org/wiki/Fundamental_theorem_of_softwar...

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.