In short: I am looking for something like Roslyn but for C++.
In detail:
I am dealing with a c# project where I have to work with c++ files. I have a bunch of .h (about 250 files) and .cpp and I would like to map the classes and functions and what not, that are defined in these files.
It is for a modeling task. I do not wish to use the actual c++ library.
I did not write the c++ code, so I cannot be sure if there are nested classes anywhere. So this is not a "simple" regex task.
The project is in c#, and the library I'd like to use is in c++. I cannot change that.
I believe libclang has the functionality you want. It's basically a C interface for accessing much of the information stored in clang's C/C++ AST. The documentation is a bit terse so here is a good video on what it can do with some examples.
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