From 59c4d10629cf7e8567ffb9759022212654c58615 Mon Sep 17 00:00:00 2001 From: Markus Schorn Date: Fri, 13 Jan 2012 15:06:00 +0100 Subject: [PATCH] Bug 368404: Testcase. --- .../tests/IndexCPPTemplateResolutionTest.java | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/internal/index/tests/IndexCPPTemplateResolutionTest.java b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/internal/index/tests/IndexCPPTemplateResolutionTest.java index f999d7a8909..56972251173 100644 --- a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/internal/index/tests/IndexCPPTemplateResolutionTest.java +++ b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/internal/index/tests/IndexCPPTemplateResolutionTest.java @@ -1927,5 +1927,25 @@ public class IndexCPPTemplateResolutionTest extends IndexBindingResolutionTestBa public void testSpecializationInIndex_367563b() throws Exception { getBindingFromASTName("type type", 4, ITypedef.class); } + + // template struct remove_const_impl {}; + // template struct remove_const_impl { + // typedef T type; + // }; + // template struct remove_const_impl { + // typedef T type; + // }; + // template struct remove_const { + // typedef typename remove_const_impl::type type; + // }; + // template struct foo; + // template <> struct foo { + // typedef int type; + // }; + // typedef foo::type>::type t; // ERROR HERE + public void testCurrentInstanceOfClassTemplatePartialSpec_368404() throws Exception { + ITypedef tdef= getBindingFromASTName("type t;", 4, ITypedef.class); + assertEquals("int", ASTTypeUtil.getType(tdef, true)); + } }