[antlr-interest] More, Status of C++ backend?

Mark Wright markwright at internode.on.net
Tue Jan 1 19:37:32 PST 2008


> Possible, but the C runtime already has a string too and I prefer to 
> keep away from third party dependencies, even if they are decent ones.
>
> Jim

Hello Jim,

That sounds perfectly reasonable.  I agree with whatever you decide
on free work you are doing for us :-) (I am also working on a freeware
software project).

Just another crazy idea which you can ignore if you wish:

Since flex_string is API compatible with std::string, *if* you
wanted to use std::string by default in the ANTLR C++ runtime,
then maybe the ANTLR C++ runtime header files could look for a C
pre-processor #define before deciding to #include <string>, so that
the user could optionally plug in flex_string if they wanted to.
The user could create a typedef of their chosen flex_string
in a header file that is #include'd before the ANTLR C++ runtime
header files. 

Thanks, Mark

-- 


More information about the antlr-interest mailing list