Title
Typedefs in function definitions
Status
cd2
Section
9.2.4 [dcl.typedef]
Submitter
Jon Caves

Created on 2006-04-21.00:00:00 last changed 178 months ago

Messages

Date: 2009-03-15.00:00:00

[Voted into the WP at the March, 2009 meeting.]

Date: 2008-09-15.00:00:00

Proposed resolution (September, 2008):

Change 9.2.4 [dcl.typedef] paragraph 1 as follows:

...The typedef specifier shall not be used in a function-definition (9.5 [dcl.fct.def]), and it shall not be combined in a decl-specifier-seq with any other kind of specifier except a type-specifier, and it shall be used neither in the decl-specifier-seq of a parameter-declaration (9.3.4.6 [dcl.fct]) nor in the decl-specifier-seq of a function-definition (9.5 [dcl.fct.def]).
Date: 2008-03-15.00:00:00

Proposed resolution (March, 2008):

Change 9.2.4 [dcl.typedef] paragraph 1 as follows:

...The typedef specifier shall not be used in a function-definition (9.5 [dcl.fct.def]), and it shall not be combined in a decl-specifier-seq with any other kind of specifier except a type-specifier, and it shall not be used in the declaration of a function parameter nor in the decl-specifier-seq of a function-definition (9.5 [dcl.fct.def])...
Date: 2006-04-21.00:00:00

9.2.4 [dcl.typedef] paragraph 1 says,

The typedef specifier shall not be used in a function-definition (9.5 [dcl.fct.def])...

Does this mean that the following is ill-formed?

    void f() {
        typedef int INT;
    }
History
Date User Action Args
2010-03-29 00:00:00adminsetstatus: wp -> cd2
2009-08-03 00:00:00adminsetstatus: dr -> wp
2009-03-23 00:00:00adminsetmessages: + msg2023
2009-03-23 00:00:00adminsetstatus: ready -> dr
2008-10-05 00:00:00adminsetmessages: + msg1761
2008-10-05 00:00:00adminsetstatus: review -> ready
2008-05-18 00:00:00adminsetmessages: + msg1654
2008-05-18 00:00:00adminsetstatus: drafting -> review
2006-11-05 00:00:00adminsetstatus: open -> drafting
2006-04-21 00:00:00admincreate