Defect Report #046

Submission Date: 10 Dec 92
Submittor: WG14
Source: X3J11/92-041 (Neal Weidenhofer)
Question 1
In subclause 6.7.1, page 82, line 9, it says, ``An identifier declared as a typedef name shall not be redeclared as a parameter.''
The question I have is: Does that sentence stand by itself absolutely or is it intended to be read in the context of the paragraph in which it appears?
The beginning of the paragraph says, ``If the declarator includes an identifier list, ...'' Function declarators including a parameter type list are dealt with in the preceding paragraph which says nothing about typedef names.
In other words, is the following valid Standard C?
typedef int foo;
int bar(int foo) {return foo; }

Response
The sentence is a part of the paragraph in which it appears. An identifier declared as a typedef name may be redeclared as a parameter in a parameter type list. The example is strictly conforming.
Previous Defect Report < - > Next Defect Report