Hi,

Best way to figure this out is to write a simple 5 line testcase that
defines a structure type and also defines a pointer to that type, and
then step through gcc to see what it does.  Try putting breakpoints in
finish_struct and build_pointer_type.

I tried with the advised test case but again I could not find how to
reference to the already declared type "MyType".

As it sould be logically, there should be a way to get a reference to
the declared type i.e.
tree type_decl = lookup_name("MyType");
tree type_ptr = build_pointer_type(type_decl->type_node);
tree var_decl = build(VAR_DECL, get_identifier("t"), type_ptr);

I tried similar codes like the above, but I don't know how to retrieve
the "type" from the type declaration. Any help, ideas are highly
appreciated.

Ferad Zyulkyarov

Reply via email to