Comment on Does this compiler exist?
spykyvenator@programming.dev 11 months agoI don’t think that, but it could be. Variables, functions and things like loops, switches and if statements are things that most programming languages have in common. They can be specified without forcing a specific syntax and already take you far from turing machines.
stifle867@programming.dev 11 months ago
I’m starting to understand what you’re saying. It wouldn’t be a universal programming language because even those things you list are not universal.
So now I am imagining a system very roughly where you could say (for example):
Is that more along the lines of what you are envisioning?
spykyvenator@programming.dev 11 months ago
Yes, indeed, I had a hard time explaining this but its what I mean.
stifle867@programming.dev 11 months ago
Interesting. I don’t see any immediately obvious technical reasons why this wouldn’t be possible.
There are languages that include a variety of different programming paradigms (I’m thinking of D). I can’t think of any that support different syntaxes but I’m sure one would exist. However, a language that is configurable I feel does not exist and could be an interesting experiment.
I still do fear however, that any attempt would still not be practical as if you design a language feature that os generic enough to work with/without other features and with different syntaxes then it would not be specific enough to be clearly useful. In other words by trying to support everything it becomes good at nothing.
ericjmorey@programming.dev 11 months ago
OCaml has 2 syntax variations. The original OCaml syntax and ReasonML.