This is the mail archive of the
mailing list for the GCC project.
Re: C PreProcessor GCC-specific features ideas.
- From: gwenael chailleu <gwenael dot chailleu at gmail dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: Solal <solal dot rastier at me dot com>, GCC Development <gcc at gcc dot gnu dot org>
- Date: Wed, 23 Apr 2014 09:52:34 +0200
- Subject: Re: C PreProcessor GCC-specific features ideas.
- Authentication-results: sourceware.org; auth=none
- References: <53569B0B dot 9040101 at me dot com> <CAKOQZ8yC292UjrHuLR0SNtETVH2dtGp2P0avYw8Em-nRaPSOfg at mail dot gmail dot com>
Ian is right, m4 corresponds better to what you've got in mind....
Your idea (strengthening the preprocessing phase) of C is already
(mostly) implemented : it is called Cawen. Please have a look at :
In short : C99 + m4 = Cawen
And your idea is a very good one !
It is almost frightening to see what can be done with a little type
introspection, a serious preprocessing phase, very few builtin
patterns and good old C99 : namely all the C++ present and future
magic tricks written in a more elegant style + a much more powerful
templating system + a much easier profiling and runtime analysis
(Cawen produces C, not C++)...
Our first benchmarks aren't that bad :
At the moment, we lack resources to create an open source project and
we use Cawen as an internal tool.
TS & GC
2014-04-23 2:18 GMT+02:00 Ian Lance Taylor <firstname.lastname@example.org>:
> On Tue, Apr 22, 2014 at 9:38 AM, Solal <email@example.com> wrote:
>> I've got ideas for improve the preprocessor with specific features.
>> The basic idea is to make the preprocessing language a complete
>> programming language.
> We are very unlikely to add such features to GCC unless they first
> become part of the C or C++ language standard.
> There are other preprocessors better suited for general purpose
> programming, such as m4.