This might be the worst argument for anything I've read this week, there's got to be a name for this logical fallacy
This might be the worst argument for anything I've read this week, there's got to be a name for this logical fallacy
It's a repeated observation that keeps coming true. DSLs have a tendency to become turing complete over time.
- It happened to wikipedia's templating language
- It happened to PHP
- It happened to mod_rewrite
- It happened to server-side includes
- etc...
It just keeps happening.
In fact it's such a problem with infrastructure teams that use yaml/json configs that you see a lack of turing-completeness being advertised as a feature (see Dhall configuration language).
But "we can't give something to users because otherwise they'll ask for other stuff" is not an argument. They're _already_ asking for stuff (templating) anyway. No one is suggesting that shutting users up is a reason to implement templating, it's the trade-offs of this feature that are debated. And if it gets implement then yes, users will certainly ask for more features, the trade-offs of which can be debated.
If you think that the line for HTML features is where we already are, you can present your arguments for why (tbh I'll probably agree). But "if you enable templating devs are then going to ask for more" isn't one.
If the other 10% of features are implemented, then any further change makes the DSL turing complete.
It's not even really `if` by itself, conditionals are good enough. Templates with for loops that can check if an index is the first or last can implement if statements. Also templates that can nest other templates recursively with a max recursion depth can also implement if.
You have to go out of your way to avoid turing completeness if you want to avoid a complexity explosion.