@@ -28182,7 +28182,7 @@ maybe_aggr_guide (tree tmpl, tree init, vec<tree,va_gc> *args)
tsubst_flags_t complain = tf_none;
tree parms = NULL_TREE;
- if (TREE_CODE (init) == CONSTRUCTOR)
+ if (BRACE_ENCLOSED_INITIALIZER_P (init))
{
init = reshape_init (type, init, complain);
if (init == error_mark_node)
new file mode 100644
@@ -0,0 +1,7 @@
+// PR c++/93596
+
+template <typename> struct A {};
+template <typename> struct B {};
+template <typename> struct C {
+ void foo () { B a = A<int> { foo }; } // { dg-error "" }
+};