Re: Compiler support for preprocessors (was: Using noweb with sml)

nr@cs.purdue.edu (Norman Ramsey)
23 Feb 1996 18:27:00 -0500

          From comp.compilers

Related articles
Re: Compiler support for preprocessors (was: Using noweb with sml) nr@cs.purdue.edu (1996-02-23)
Re: Compiler support for preprocessors (was: Using noweb with sml) nr@cs.purdue.edu (Norman Ramsey) (1996-03-01)
| List of all articles for this month |
From: nr@cs.purdue.edu (Norman Ramsey)
Newsgroups: comp.compilers
Date: 23 Feb 1996 18:27:00 -0500
Organization: Compilers Central
References: <4gii2t$ovf@cantaloupe.srv.cs.cmu.edu>,
Keywords: design, standards

Michael Siff <siff@cs.wisc.edu> wrote:
>I am attempting to use noweb with sml. The notangle program has an
>optional argument, -L, which according to the noweb documentation, "emit
>pragmas that inform the compilers of the placement of lines in the noweb
>soruce." ...These pragmas are fine for C. But how can I get the SML compiler
>to recognize them?


Years ago, I lobbied the implementors of Standard ML of New Jersey for
a formal comment or other feature by which to achieve this goal. They
were not interested, in part I think because of a belief that ``one
should not have preprocessors generate ML code; one should use
functors or higher-order functions.'' I love functors and
higher-order functions, but I don't believe they are the best solution
to every problem.


Pester your favorite compiler writers and language designers to get
support for line-number pragmas. It is relatively easy to implement
(I added it to SRC Modula-3), and it is useful for all kinds of
preprocessors (e.g., yacc clones), not just for literate-programming
tools.


--
Norman Ramsey
http://www.cs.purdue.edu/homes/nr
--


Post a followup to this message

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