Fetching a character table using clang

I’m looking for a way to get the character table of a C program. I’m looking for global and local variables, their scope, etc.

Does clang have an option or API to upload this information? Or any other compiler structure that makes this easy to do.

+5
source share
1 answer

I am sure that Clang has a set of interfaces to provide access to symbol table information. I understand that the documentation is not enough, so you just need to study the source code.

GCCXML does this to determine the top level. It does not report the contents of the functions (for example, you are unlikely to get local residents). You get XML, and then you yourself.

DMS Software Reengineering Toolkit C . , API- [ IMHO] . - , , . DMS ( ) / .

+1

All Articles