This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 115d. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2024-10-26


1243. Misleading footnote regarding multiple-declarator declarations

Section: 9.3  [dcl.decl]     Status: C++11     Submitter: Johannes Schaub     Date: 2011-02-08

[Voted into the WP at the March, 2011 meeting as part of paper N3262.]

The footnote for 9.3 [dcl.decl] paragraph 3 reads,

A declaration with several declarators is usually equivalent to the corresponding sequence of declarations each with a single declarator... The exception occurs when a name introduced by one of the declarators hides a type name used by the decl-specifiers, so that when the same decl-specifiers are used in a subsequent declaration, they do not have the same meaning...

A more important exception to the rule has been added in C++0x, specifically with the auto specifier when the deduced type is not the same for all declarators, which renders the declaration ill-formed. The footnote should be updated accordingly.