On 3/03/2011, at 2:41 PM, Derek M Jones wrote:
> For the last 20 years or so my company has sold a tool that
> allows developers to specify the name of a function (user defined
> or otherwise) and various properties about its arguments and
> return value, these are used to check the source during compilation.

That's good to know.  But the properties for the standard library
functions come from the 'Programming language - C' standard, not
from the user.  That is the point I was making.  They are not
PRIVATE vocabulary.

Look, if I look at a book about a human language, such as
        An Introduction to Persian (revised 3rd edition)
        W. M. Thackston
        IranBooks 1993
you find the sections go
        Phonology and script   -- lexical structure
        Grammar  -- what it says, 25 lessons
        Classical and Archaic Usages
        Colloquial Transformations
        Dictionary (English->Persian, Persian->English)
Does this mean that the vocabulary is separable from the
"language"?  No.  Every lesson introduces vocabulary.
This is common practice in language books.  If you had a grammar
without vocabulary, what could you say?

In C, 'int' is a reserved word.  In Algol 68, it was part of the
standard prelude.  And so what?

What I *don't* see here is any practical relevance to the question
of whether 'printf' is part of the C language or not, except for
someone who is writing a parser and needs to know whether it has
special syntax.  In C, 'return' is a keyword, but most C programmers
treat it syntactically like a function call.  There are languages
in which return *is* a function call.  When I'm writing *in* a
language, if I ask the question "what is the normal way to do X in
this language", it makes no practical difference to me whether it
involve special syntax or not.  I've used languages where
"absolute value of X" is written |X|, or abs X, or abs(X).  The last
appears to use a normal function call, the middle one uses a kind of
syntax that is common (unary operators like + and -) even if this
one happens to be less usual, and the first requires a special kind
of syntax (outfix operators) that is rare.  But they are all
equally "part of the language" for someone *using* that language.
They are defined in the report or standard or whatever it's called.

The Open University is incorporated by Royal Charter (RC 000391), an exempt 
charity in England & Wales and a charity registered in Scotland (SC 038302).

Reply via email to