From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00,INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 Path: utzoo!attcan!uunet!mcvax!ukc!dcl-cs!aber-cs!thor!pcg From: pcg@thor.cs.aber.ac.uk (Piercarlo Grandi) Newsgroups: comp.lang.ada Subject: Re: What is the origin of `pragma' Message-ID: Date: 8 Jul 89 21:51:44 GMT References: <8906291247.AA19739@ti.com> <15896@vail.ICO.ISC.COM> <8254@boring.cwi.nl> Sender: pcg@aber-cs.UUCP Organization: Coleg Prifysgol Cymru In-reply-to: dik@cwi.nl's message of 7 Jul 89 10:42:55 GMT List-Id: In article <8254@boring.cwi.nl> dik@cwi.nl (Dik T. Winter) writes: In article <15896@vail.ICO.ISC.COM> rcd@ico.ISC.COM (Dick Dunn) writes: > It may or may not have any bearing, but ALGOL 68 has a construct called a > "pragmat" with very similar usage. I recall seeing it in at least one > other language of comparably ancient vintage, but I can't lay hands on the > information, and I can't recall whether it was pragma or pragmat. ALGOL 68 > uses a symbol "pr" as the delimiter. > -- This is true, but it was not in the original language. The "Report on the Algorithmic Language Algol 68" (1969) does not mention pragmats, the revised report (printed 1976, but already published earlier) does. I think it got into the language in the 1972-1974 timeframe. Apart from the curiosity value of knowing where from pragma comes, let me add: Algol 68 does have a "compiler directive" construct, very well thought out; it can be delimited either by ".pragma .... .pragma" or ".pr ..... .pr" (using dot stropping). Another language, a kind of predecessor of Ada, LIS, copied it over (do I remember correctly?) from Algol68. In any case pragma, either via LIS or directly, comes quite clearly to Ada from Algol68, as a few other features. NOTE: do you know LIS (Langage Implementation Sisteme, Level 64) and its influence on the design of Ada? Do you deal in Ada design issues? If you answered NO and YES, you might be amused by having a look at LIS, and then shelve the manual next to the ones for Jovial and Neliac :-> ... The most interesting point is that in Algol68 pragmas were supposed to deal with "pragmatics", which is different from "semantics", in other words no pragmas were allowed to give a program a different meaning than that attributed by the language definition. This is a *very* wise concept, especially as pragmas are supposed to be compiler dependent. I for one would find the notion of a pragma that is not semantically neutral a contradiction in terms... (a non semantically neutral implementation definable language construct should be called a pandora, not a pragma :->). Now, now, what is the situation for Ada? (before answering, have a look at pragma shared, and at VMS Ada for comparison...). -- Piercarlo "Peter" Grandi | ARPA: pcg%cs.aber.ac.uk@nsfnet-relay.ac.uk Dept of CS, UCW Aberystwyth | UUCP: ...!mcvax!ukc!aber-cs!pcg Penglais, Aberystwyth SY23 3BZ, UK | INET: pcg@cs.aber.ac.uk