[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Question about transformation of template parameter

Hi Markus,
Consider the following code:

template <typename T>
struct A {};

template <class U>
struct B {
ÂÂtemplate <typename T>
ÂÂstatic A<T> f();
};

What should be the return type of B<int>::f ?

Existing code produces aÂCPPMethodTemplateSpecialization ÂA<#10000>, but shouldn't it beÂA<#0> instead since the type has been taken out of the enclosing template? Is there any function that would perform this kind of transformation?

This is related to my attempt to fixÂAST2TemplateTests.testTemplateConversionOperator_271948_2 in a clean way.

-sergey