Re: Formal semantics of language semantics

"Joachim Durchholz" <joachim_d@gmx.de>
29 Sep 2002 15:47:11 -0400

          From comp.compilers

Related articles
Formal semantics of language semantics j*lstnme*@uiuc.edu (Joe Hendrix) (2002-09-25)
Re: Formal semantics of language semantics loewis@informatik.hu-berlin.de (Martin v. =?iso-8859-1?q?L=F6wis?=) (2002-09-29)
Re: Formal semantics of language semantics nmm1@cus.cam.ac.uk (Nick Maclaren) (2002-09-29)
Re: Formal semantics of language semantics i.dittmer@fh-osnabrueck.de (Ingo Dittmer) (2002-09-29)
Re: Formal semantics of language semantics joachim_d@gmx.de (Joachim Durchholz) (2002-09-29)
Re: Formal semantics of language semantics stephen@dino.dnsalias.com (Stephen J. Bevan) (2002-09-29)
Re: Formal semantics of language semantics lex@cc.gatech.edu (Lex Spoon) (2002-09-29)
Re: Formal semantics of language semantics whopkins@alpha2.csd.uwm.edu (Mark) (2002-09-29)
Re: Formal semantics of language semantics nmm1@cus.cam.ac.uk (Nick Maclaren) (2002-10-13)
Re: Formal semantics of language semantics haberg@matematik.su.se (Hans Aberg) (2002-10-13)
Re: Formal semantics of language semantics scgupta@solomons.cs.uwm.edu (Satish C. Gupta) (2002-10-13)
[12 later articles]
| List of all articles for this month |
From: "Joachim Durchholz" <joachim_d@gmx.de>
Newsgroups: comp.compilers
Date: 29 Sep 2002 15:47:11 -0400
Organization: Compilers Central
References: 02-09-149
Keywords: semantics
Posted-Date: 29 Sep 2002 15:47:11 EDT

Joe Hendrix wrote:
> Are there any notations commonly used to define the semantics of a
> programming language? (Similar to how BNF defines the syntax).


There are many notations, but none is common. Most have the problem
that expressing the semantics in them is longer than simply writing
down some code that "does the right thing". Those few notations that
don't have this problem are usually difficult to implement
efficiently.


And those that are both easy to write and efficiently implementable
are so near to being a programming language themselves that they tend
to become full programing languages almost naturally. The engine that
processes them is already a programming language interpreter, all you
need after that is adding a compiler, maybe a debugger, some libraries
that go beyond what's needed for programming language specification...


As a loosely related example, consider the ML family of languages.
Initially, there was a theorem prover, the language for specifying
theorems and proofs being ML. (I don't know whether that prover was
ever used to specify programming language semantics. It would have
been possible, because if you have a constructive proof that a
function exists, that proof can be automatically transformed into a
program that computes the function.)


Today, ML is the ancestor of two languages that are in near-production
use (SML and OCaml), and a plethora of research languages.


Regards,
Joachim


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.