The type category in a function definition cannot be inherited from a typedef.

This commit is contained in:
acqn
2023-10-05 17:48:16 +08:00
parent 12193790e5
commit 0028b14071
3 changed files with 40 additions and 10 deletions

View File

@@ -0,0 +1,6 @@
/* Bug #2020 - ISO/IEC 9899:1999 (E), 6.9.1 footnote 137:
** "The intent is that the type category in a function definition cannot be inherited from a typedef"
*/
typedef void F(void);
F c { } /* Should fail */