Does anyone know of any C parser library for .NET?
(I'm intending to parse C code into some form of object graph, so I can convert it to a different language.)
A proper C99 grammar is not that trivial. It's better to use a proven C parser (e.g., Clang). It is possible to use it with .NET via C++/CLI.
ANTLR can do what you'd like. It has a C preprocessor and ANSI C grammar.
https://github.com/antlr/grammars-v4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With