-
Notifications
You must be signed in to change notification settings - Fork 15.5k
Open
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzillac11clang:frontendLanguage frontend issues, e.g. anything involving "Sema"Language frontend issues, e.g. anything involving "Sema"confirmedVerified by a second partyVerified by a second partyrejects-valid
Description
| Bugzilla Link | 40147 |
| Version | trunk |
| OS | All |
| CC | @pascal-cuoq,@hfinkel,@zygoloid |
Extended Description
Test case (prog.c):
int main()
{
typedef const int t();
typedef int t();
}Compilation command line:
clang prog.c -Wall -Wextra -std=c11 -pedantic-errors Observed behaviour:
The following error message was outputed:
error: typedef redefinition with different types ('int ()' vs
'const int ()') typedef int t();
Expected behaviour:
No error message. Both typedefs should define t to be of type 'int ()' since
function types never have qualified return types.
Standard references:
6.7.6.3.5
Note:
gcc does not give any errors for the program.
Metadata
Metadata
Assignees
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzillac11clang:frontendLanguage frontend issues, e.g. anything involving "Sema"Language frontend issues, e.g. anything involving "Sema"confirmedVerified by a second partyVerified by a second partyrejects-valid