Thursday, August 30, 2007

Fundamental Theories of Programming Languages

A well-designed programming language will have a coherent and consistent design philosophy underlying it. This design philosophy governs what features should, and should not, be explicitly included within the language, and therefore also guides the evolution of the language over its lifetime of use. The syntactic and semantic form and function of language features, and how they interoperate with one another, should reflect that philosophy, both in the initial language definition and in the features that accrue to it over time.

Because understanding this design philosophy explains how a programming language is supposed to work and be used, we have what amounts to specific theories for specific programming languages. Languages having a theory (or design philosophy) thus have an overarching principle around which the programming language was designed. That principle is The Fundamental Theory of that language, because it explains (or should explain) why all the pieces of the language are the way they are.

A developer who is aware of the Fundamental Theory of the language they're working with (assuming it has one, not all do) then has a guide on how best to exploit the language and its features. Rather than struggling with the structure of the language, a developer can get in sync with its FT and understand how best to fit together and exploit its pieces to accomplish a given task. While coding standards for programming languages are common, they're rarely conciously derived from the language's FT and instead end up being a collection of formatting strictures and illustrations of how to write code in the particular language that embody "good practices". All well and fine, but these usually end up being ad hoc collections based on developers' past experiences and preferences, and don't reflect a deep understanding of the language's design philosophy--i.e. its Fundamental Theory.

In upcoming "Fundamental Theory of Language X" postings I'm going to identify what I believe to be various programming languages' FTs, how well the definition of the language conforms to that Theory, and what's happening to the language's conformance to its own fundamentals as it evolves over time. Some languages have little or no evidence of an FT, and some of those will be called out as well.

As opposed to most punditry, I'm going to limit myself to those languages that I've actually used, rather than make assertions and draw definitive conclusions in areas about which I know little or nothing. (Though I may make a few comments on some languages from the perspective of one looking to learn them and whether I perceive them to have an identifiable Fundamental Theory that would aid learning and exploiting them. :-)

1 comment:

Sankar lp said...

very good write up on fundamental theories of programming languages.Before writing the coding for the program, programmers has to has lay the algorithm of the program.

sankar
java training in chennai