Getting type information from AST [message #1765086] |
Tue, 06 June 2017 09:05  |
Eclipse User |
|
|
|
Hi,
I'm working on a plugin for C code generation which is based on the CDT.
I'm trying to retrieve type information for return values and parameters for functions.
Therefore I get IFunction instances from the AST and use the type information for the IParameter instances and the return type of the function itself.
The problem I currently have usign this method is, that I cannot get the original string of a type but only the string that is returned by getName of ICompositeType or ITypedef.
If the type was defined using a #define directive (e.g. #define TYPE_CHAR_P char* ), that name is no retrievable. getType returns a type that already resolves to char* but I would need TYPE_CHAR.
Is there a way to get the original string?
Regards
Marcus
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03034 seconds