Related articles |
---|
Ann: Minimac - A simple open source macro processor mwhibsi@gmail.com (mwh) (2009-05-05) |
From: | mwh <mwhibsi@gmail.com> |
Newsgroups: | comp.compilers |
Date: | Tue, 5 May 2009 05:41:08 -0700 (PDT) |
Organization: | Compilers Central |
Keywords: | macros |
Posted-Date: | 05 May 2009 10:50:37 EDT |
I've recently started an open source project to produce a minimalist
text macro processor suitable as a front end preprocessor for little
language compilers.
Minimac is a BSD licensed open source project written in ANSI C. The
project is hosted on Google code http://code.google.com/p/minimac/
Salient features and design objectives:
* simpler to use than m4
* uses an explicit argument stack, user functions are defined by
concatenation
* delays macro expansion to the last possible moment.
Usage Sample:
Minimac's output has been prefixed with '=>':
`greet`Hello friend`
=>
greet
=>Hello friend
`friend`George`
=>
friend
=>George
greet
=>Hello George
`friend`Ann`
=>
friend
=>Ann
greet
=>Hello Ann
Cheers,
Mark Humphries
[Take a look at GPM, the tiny macrogenerator that ballooned into m4. -John]
Return to the
comp.compilers page.
Search the
comp.compilers archives again.