On Fri, May 2, 2008 at 11:39 AM, Peter Collingbourne <[EMAIL PROTECTED]> wrote: > In the C++ frontend, record_types maintain list(s) of the parameters > which were used to instantiate the type, one list for each "level" of > the instantiation. I would like to know how to determine the list of > parameters that were used to instantiate "this" type e.g. in the case of > a type foo<int>::bar<long> I would like the tree_vec containing the type > "long". Note that we can't always simply extract the last list of > parameters e.g. for the type foo<int>::baz the tree_vec required would > be empty or null whereas the tree_vec available has a single level for > "int".
INNERMOST_TEMPLATE_ARGS can be used to get at the "innermost" TREE_VEC of template arguments for a class template specialzation such as foo<int>::bar<long>. CLASSTYPE_USE_TEMPLATE != 0 tells you whether a RECORD_TYPE is actually a template - Doug