Sunday, February 10, 2008

Programming Languages Are A Superset Of DSLs

In the sense that anyone who makes a DSL does so within a subset of a fully-featured programming language, of course, this is obvious.

But if you're just looking at that end of the truth, you don't see the interesting part.

The interesting part is that English can express anything a programming language can express, but English was also designed to accomodate ambiguities and nuances that are useful when speaking to people, but not useful when proscribing actions for Turing machines.

Programming languages are subsets of English specific to the domain of Turing machines.

(They aren't inherently subsets of English - that's an incidental attribute, rather than an inherent one - but all the programming languages I'm aware of are subsets of English, even my current favorite, which comes from Japan.)

This may only be interesting to linguists, but it explains certain mysterious phenomena linking poetry to programming languages.