* pt.c (type_dependent_expression_p): A non-type template parm with
a placeholder type is type-dependent.
From-SVN: r270984
+2019-05-07 Jason Merrill <jason@redhat.com>
+
+ * pt.c (type_dependent_expression_p): A non-type template parm with
+ a placeholder type is type-dependent.
+
2019-05-06 Marek Polacek <polacek@redhat.com>
PR c++/90265 - ICE with generic lambda.
return false;
}
+ /* The type of a non-type template parm declared with a placeholder type
+ depends on the corresponding template argument, even though
+ placeholders are not normally considered dependent. */
+ if (TREE_CODE (expression) == TEMPLATE_PARM_INDEX
+ && is_auto (TREE_TYPE (expression)))
+ return true;
+
gcc_assert (TREE_CODE (expression) != TYPE_DECL);
/* Dependent type attributes might not have made it from the decl to