|Subject:||Re: [Tinycc-devel] tcc optional argument as in C++|
|Date:||Mon, 20 Feb 2012 16:06:57 +0100|
To me, there is no need to write a new compiler for that. A preprocessor is enough (remember that first Barne’s C++ compiler, at least until 2.0, was a pre-processor)
The benefit of pre-processor is that it can be used with other C compilers.
address@hidden may want to add more syntactic sugar and extend his preprocessor with, say, position independent arguments
void copy(void*dest, const void*src, int deepcopy=0);
copy(src: s, dest: d);
From: address@hidden [mailto:address@hidden On Behalf Of David Mertens
I agree with Christian. However, if the need is great, why not write your own compiler that uses libtcc and handles that preprocessing for you? You could copy the current tcc.c and modify it in a handful of places and you'd have your own derived compiler. Note that I'm not suggesting that you fork tcc and hack on this feature. Rather, start a new project that clearly depends on and derives from tcc/libtcc which has just the .c file and a Makefile.
|[Prev in Thread]||Current Thread||[Next in Thread]|