PR c++/56543
* tree.c (strip_typedefs): Don't copy args if they are NULL.
* g++.dg/template/typename20.C: New test.
From-SVN: r196491
+2013-03-06 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/56543
+ * tree.c (strip_typedefs): Don't copy args if they are NULL.
+
2013-03-05 Jakub Jelinek <jakub@redhat.com>
* parser.c (cp_parser_braced_list): For {} initialize
case TYPENAME_TYPE:
{
tree fullname = TYPENAME_TYPE_FULLNAME (t);
- if (TREE_CODE (fullname) == TEMPLATE_ID_EXPR)
+ if (TREE_CODE (fullname) == TEMPLATE_ID_EXPR
+ && TREE_OPERAND (fullname, 1))
{
tree args = TREE_OPERAND (fullname, 1);
tree new_args = copy_node (args);
+2013-03-06 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/56543
+ * g++.dg/template/typename20.C: New test.
+
2013-03-05 Jakub Jelinek <jakub@redhat.com>
PR debug/56510
--- /dev/null
+// PR c++/56543
+
+template <typename>
+struct S;
+
+template <typename T>
+struct U
+{
+ typedef typename S <T>::template V <> W;
+ S <W> x;
+};