Antlr3 had one, and it'd be awesome if Antlr4 did, too.
I'm currently working with c++ target and there are some feature requests that I'd like to see in C target:
std::string
s can be replaced with std::string_view
s. In C, it is natural to use non-owning char*
s to reference strings, so this should not be an issue);I'd also like to see CI with sanitizers and fuzzing (C++ target have some UBs and leaks that I can't properly trace).
FYI i've started looking into how ATN works and making some drafts for C runtime.
FYI i've started looking into how ATN works and making some drafts for C runtime.
Fantastic. Thank you!
Bump :)
Well I'm still on it, but things are moving quite slowly because my job takes all the time.
So far I've implemented basic support structures — list, hashmap, interval set, memory pool etc., I also have ATN classes and deserialization for them. I'm working on lexer simulator and DFA.
You can track progress in my fork. Some code review would be appreciated.
Maybe it would be better to create C wrapper for C++ runtime implementation.
I am not saying the that C target is bad idea. But considering the time required for development of the C++ target, the complexity of the implementation....
It makes me think that we should really work on single C compatible runtime. It seems to me that the C++ runtime is not finished and I am not sure when it will be done.
Most helpful comment
Maybe it would be better to create C wrapper for C++ runtime implementation.
I am not saying the that C target is bad idea. But considering the time required for development of the C++ target, the complexity of the implementation....
It makes me think that we should really work on single C compatible runtime. It seems to me that the C++ runtime is not finished and I am not sure when it will be done.