3 ms·
Well puppet doesn't have loops. I hope that's not because the "fad" is ending.
by swiley 5y ago
Well puppet doesn't have loops. I hope that's not because the "fad" is ending.
- lostcolony 5y agoThere are plenty of further restrictions (such as immutable languages that don't have loops, because loops require mutation, and so instead rely on recursion), or which eschew being concerned about control flow at all (such as puppet, SQL, Prolog, etc; any declarative language). Certainly, those languages aren't "undoing" structured programming.
- masklinn 5y ago> such as immutable languages that don't have loops, because loops require mutation, and so instead rely on recursion These two are not as intertwined as you make them. OCaml has mutation but not iteration.
- int_19h 5y agoOCaml has while- and for-loops. A better example might be Clojure, which has mutable variables (opt-in, like OCaml), but no traditional imperative loops - only recursion. However, even then, the syntax for its tail-recursive construct uses "loop" as a keyword.
- lostcolony 5y agoI said immutable -> !loops (p implies not q). You're saying !immutable -/> loops (not p does not imply q) It's a fair thing to mention, but you're not gainsaying anything I said; I never said anything about mutable languages that don't have loops. In fact, to the topic at hand, you would assume that to be the case, given that structured programming was intended to force loops on languages at the time (mostly mutable) that weren't using them (but instead were using gotos and the like)