This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 114a. See for the official list.


2070. using-declaration with dependent nested-name-specifier

Section:  [class.qual]     Status: CD6     Submitter: Richard Smith     Date: 2015-01-15

[Accepted at the November, 2020 meeting as part of paper P1787R6 and moved to DR at the February, 2021 meeting.]

It makes no sense for a user to write a class template that contains a using-declaration that is sometimes an inheriting constructor declaration and sometimes pulls in a named value from a base class; These are sufficiently different things that we're doing them a disservice by conflating them. We're also doing a disservice to all readers of the code, by allowing an inheriting constructor to be written using a syntax that does not look like one.

In an inheriting constructor using-declaration, the nested-name-specifier and the unqualified-id should be required to be the same identifier.

Notes from the May, 2015 meeting:

The consensus of CWG was that the same name should be required when the nested-name-specifier is dependent and in the using-declaration case but should be allowed to be different in all other cases. See also issues 156 and 399.