[PATCH] D131499: Change prototype merging error into a warning for builtins
Erich Keane via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 9 08:12:07 PDT 2022
erichkeane added inline comments.
================
Comment at: clang/test/Sema/prototype-redecls.c:32
// clear that the previous declaration was a builtin.
-float rintf() { // expected-error {{conflicting types for 'rintf'}} \
+float rintf() { // expected-warning {{incompatible redeclaration of library function 'rintf'}} \
expected-note {{'rintf' is a builtin with type 'float (float)'}}
----------------
Hmm... this is a definition of a builtin with a completely incompatible prototype. Do we REALLY want this to not be an error?
I guess I could see it being OK with declarations, but it is odd with a definition that is incompatible.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131499/new/
https://reviews.llvm.org/D131499
More information about the cfe-commits
mailing list