<HTML>
<HEAD>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<TITLE>
    CWG Issue 1738</TITLE>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<STYLE TYPE="text/css">
  INS { text-decoration:none; font-weight:bold; background-color:#A0FFA0 }
  .INS { text-decoration:none; background-color:#D0FFD0 }
  DEL { text-decoration:line-through; background-color:#FFA0A0 }
  .DEL { text-decoration:line-through; background-color: #FFD0D0 }
  @media (prefers-color-scheme: dark) {
    HTML { background-color:#202020; color:#f0f0f0; }
    A { color:#5bc0ff; }
    A:visited { color:#c6a8ff; }
    A:hover, a:focus { color:#afd7ff; }
    INS { background-color:#033a16; color:#aff5b4; }
    .INS { background-color: #033a16; }
    DEL { background-color:#67060c; color:#ffdcd7; }
    .DEL { background-color:#67060c; }
  }
  SPAN.cmnt { font-family:Times; font-style:italic }
</STYLE>
</HEAD>
<BODY>
<P><EM>This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21
  Core Issues List revision 118b.
  See http://www.open-std.org/jtc1/sc22/wg21/ for the official
  list.</EM></P>
<P>2025-09-28</P>
<HR>
<A NAME="1738"></A><H4>1738.
  
Explicit instantiation/specialization of inheriting constructor templates
</H4>
<B>Section: </B>_N4527_.12.9&#160; [<A href="https://wg21.link/class.inhctor">class.inhctor</A>]
 &#160;&#160;&#160;

 <B>Status: </B>C++14
 &#160;&#160;&#160;

 <B>Submitter: </B>Daveed Vandevoorde
 &#160;&#160;&#160;

 <B>Date: </B>2013-08-16<BR>


<P>[Moved to DR at the February, 2014 meeting.]</P>

<P>It is not clear whether it is permitted to explicitly instantiate
or explicitly specialize specializations of inheriting constructor
templates.  Since inheriting constructors are considered to be implicitly
declared (_N4527_.12.9 [<A href="https://wg21.link/class.inhctor#1">class.inhctor</A>] paragraph 1), it might be inferred
that 13.9.3 [<A href="https://wg21.link/temp.explicit#4">temp.explicit</A>] paragraph 4 forbids their explicit
instantiation:</P>

<BLOCKQUOTE>

If the declaration of the explicit instantiation names an
implicitly-declared special member function (
11.4.4 [<A href="https://wg21.link/special">special</A>]), the program is ill-formed.

</BLOCKQUOTE>

<P>Similarly, an explicit specialization provides a definition for the
specialized member, and 11.4.4 [<A href="https://wg21.link/special#1">special</A>] paragraph 1 forbids
defining an implicitly-declared special member function.</P>

<P>These inferences do not seem conclusive, however, so an explicit
statement in _N4527_.12.9 [<A href="https://wg21.link/class.inhctor">class.inhctor</A>] would be helpful.</P>

<P>(See also <A HREF="1780.html">issue 1780</A>.)</P>

<P><B>Proposed resolution (January, 2014):</B></P>

<P>Change _N4527_.12.9 [<A href="https://wg21.link/class.inhctor#4">class.inhctor</A>] paragraph 4 as follows:</P>

<BLOCKQUOTE>

A constructor so declared has the same access as the
corresponding constructor in <TT>X</TT>. It is deleted if the
corresponding constructor in <TT>X</TT> is deleted
(9.6 [<A href="https://wg21.link/dcl.fct.def">dcl.fct.def</A>]). <INS>An inheriting constructor
shall not be explicitly instantiated (13.9.3 [<A href="https://wg21.link/temp.explicit">temp.explicit</A>])
or explicitly specialized (13.9.4 [<A href="https://wg21.link/temp.expl.spec">temp.expl.spec</A>]).</INS>

</BLOCKQUOTE>

<BR><BR>
</BODY>
</HTML>
