Title
Redundant specification for default arguments
Status
review
Section
9.3.4.7 [dcl.fct.default]
Submitter
Yin Xinyu

Created on 2026-09-22.00:00:00 last changed 2 weeks ago

Messages

Date: 2026-10-15.00:00:00

Proposed resolution (October, 2026):

  1. Change in9.3.4.6 [dcl.fct] paragraph 13 as follows:

    [Note: The return type, the parameter-type-list, the ref-qualifier , the cv-qualifier-seq, and the exception specification, but not the default arguments (9.3.4.7 [dcl.fct.default]) or the trailing requires-clause (9.3 [dcl.decl]), are part of the function type. [Note 6: Function types are checked during the assignments and initializations of pointers to functions, references to functions, and pointers to member functions. —end note]
  2. Change in 9.3.4.7 [dcl.fct.default] paragraph 11 as follows:

    [Note: A default argument is not part of the type of a function. [Example 9: ... -- end example ] -- end note]
Date: 2026-10-07.20:57:02

CWG 2026-10-06

CWG noticed that 9.3.4.6 [dcl.fct] paragraph 13 is, in turn, redundant with 9.3.4.6 [dcl.fct] paragraph 1.

Date: 2026-09-15.00:00:00

Suggested resolution (September, 2026):

Change in 9.3.4.7 [dcl.fct.default] paragraph 11 as follows:

[Note: A default argument is not part of the type of a function. [Example 9: ... -- end example ] -- end note]
Date: 2026-09-22.00:00:00

(From submission #1011.)

Subclause 9.3.4.7 [dcl.fct.default] paragraph 11 says

... A default argument is not part of the type of a function. ...

However, 9.3.4.6 [dcl.fct] paragraph 13 already says as much:

The return type, the parameter-type-list, the ref-qualifier , the cv-qualifier-seq, and the exception specification, but not the default arguments (9.3.4.7 [dcl.fct.default]) or the trailing requires-clause (9.3 [dcl.decl]), are part of the function type.
History
Date User Action Args
2026-10-07 20:57:02adminsetmessages: + msg8702
2026-10-07 20:57:02adminsetmessages: + msg8701
2026-10-07 20:57:02adminsetstatus: open -> review
2026-10-04 10:23:05adminsetmessages: + msg8693
2026-09-22 00:00:00admincreate