comp.lang.ada
 help / color / mirror / Atom feed
From: spear@cs.nps.navy.mil (Jon Spear)
Subject: Re: Tool to expand generics?
Date: 1995/04/19
Date: 1995-04-19T00:00:00+00:00	[thread overview]
Message-ID: <D79nuz.K4G@taurus.cs.nps.navy.mil> (raw)
In-Reply-To: 3n1jtk$a0v@Starbase.NeoSoft.COM

In article <3n1jtk$a0v@Starbase.NeoSoft.COM>,
David Weller <dweller@Starbase.NeoSoft.COM> wrote:
>The odd problem is you're looking for a "macro expansion" tool, which
>is quite common with C++ compilers (well, it used to be, to
>circumvent problems with templates.  I'm not too up to date on C++
>compilers anymore, I've been "++" free for over nine months now :-),
>but the Ada community never really had such a critter.

There are versions of Knuth's WEB system that support Ada.  Among other
things, this allows the construction of complex (or simple) macros that
will be expanded into Ada code before compilation.  For more info,
consult the newsgroup comp.programming.literate or the FAQ:

ftp://rtfm.mit.edu/pub/usenet-by-group/comp.answers/literate-programming-faq

However, it won't expand standard Ada generic instantiations.  

Most C/C++ compilers allow you to save the preprocessor output, after
macro expansion.  It seems reasonable that if there were still Ada
compilers around that implemented generics as macros (as some early
compilers did), they might have an option to save the expanded code. 

-Jon
-- 
|Jon Spear (spear@cs.nps.navy.mil)|Ada95: The World's First International-  |
|Comp Sci Dept, Code CS/Sj, x2830 |Standard OOPL. http://lglwww.epfl.ch/Ada/|




      parent reply	other threads:[~1995-04-19  0:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3mu3bs$ptf@sequoia.jrs.com>
     [not found] ` <3n0t9c$24k@sequoia.jrs.com>
     [not found]   ` <3n113i$fg6@pulsar.sky.net>
     [not found]     ` <3n1jtk$a0v@Starbase.NeoSoft.COM>
1995-04-18  0:00       ` Tool to expand generics? Robert Dewar
1995-04-19  0:00       ` Jon Spear [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox