1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-23 14:42:11 +02:00

Test case for bug 245049.

This commit is contained in:
Sergey Prigogin 2008-08-24 19:44:04 +00:00
parent ca322a621a
commit 9acb20d524

View file

@ -2158,6 +2158,26 @@ public class AST2TemplateTests extends AST2BaseTest {
assertInstance(f1.getParameters()[0].getType(), ICPPTemplateInstance.class);
}
// struct A {};
//
// template <class T>
// void func(const T& p) {
// }
//
// void test() {
// A a1;
// const A a2;
// func(a1);
// func(a2);
// }
public void _testFunctionTemplate_245049() throws Exception {
BindingAssertionHelper bh= new BindingAssertionHelper(getAboveComment(), true);
ICPPFunction b0= bh.assertNonProblem("func(a1)", 4, ICPPFunction.class);
assertInstance(b0, ICPPTemplateInstance.class);
ICPPFunction b1= bh.assertNonProblem("func(a2)", 4, ICPPFunction.class);
assertEquals(b0, b1);
}
// namespace ns {
//
// template<class _M1, class _M2>