Hacker News new | ask | show | jobs
by tptacek 4981 days ago
All of structured programming consists of various controlled forms of goto.
2 comments

Yesterday, I found an email from Jon Callas where he was giving advice on where SAML falls in the Chomsky hierarchy of languages:

"If it has backwards gotos in any form, it's Turing-complete. Loops, recursion, etc. are backwards gotos. If-then-else is a forward goto."

I hadn't ever thought of things that way, but I thought it was interesting.

Once you've worked in assembly language, you realize everything is just another form of jmp.
That's the point of the article, though: callbacks don't offer enough structure to effectively reason about.