[GCC-XML]Structs generated by gcc

Brad King brad.king at kitware.com
Thu May 13 16:23:22 EDT 2004


Brad King wrote:
> wyf at fudan.edu.cn wrote:
> 
>> Hello, Brad
>>   There are some structs generated by gcc, for example:
>>    <Struct id="_7" name="__vmi_class_type_info_pseudo1" context="_1" 
>> mangled="29__vmi_class_type_info_pseudo1" location="f0:4" file="f0" 
>> line="4" members="_17 _18 _19 _20" bases="" />
>>   <Struct id="_12" name="__class_type_info_pseudo" context="_1" 
>> mangled="24__class_type_info_pseudo" location="f1:0" file="f1" 
>> line="0" members="" bases="" />       Would you please add an 
>> "artificial" attribute for this kind of struct/class? Otherwise I 
>> can't distinguish a struct/class written by user or generated by gcc.
> 
> 
> If there is not already an "artificial" attribute then the struct nodes 
> are not marked artificial in GCC's internal representation.  What 
> version of GCC-XML produced this output?  Please send me a minimal C++ 
> file that reproduces the behavior.
> 
> In this case, though, you can safely ignore any names that start in two 
> underscores because the standard explicitly reserves these names for use 
> by the compiler.

This has been fixed:

http://www.gccxml.org/Bug/bug.php?op=show&bugid=837&pos=0

Now the name="..." attribute is just left out for anonymous 
class/struct/union types.

-Brad



More information about the gccxml mailing list