public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/100343] New: add -Wundefined-inline for inline function is used but not defined
@ 2021-04-29 22:15 msebor at gcc dot gnu.org
2022-12-27 11:49 ` [Bug c/100343] " a.samirh78 at gmail dot com
2022-12-28 19:01 ` pinskia at gcc dot gnu.org
0 siblings, 2 replies; 3+ messages in thread
From: msebor at gcc dot gnu.org @ 2021-04-29 22:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100343
Bug ID: 100343
Summary: add -Wundefined-inline for inline function is used but
not defined
Product: gcc
Version: 11.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: msebor at gcc dot gnu.org
Target Milestone: ---
Clang provides -Wundefined-inline to control the warning about used inline
functions for which no definition has been provided. GCC doesn't provide any
option to control the warning. This is a request to add -Wundefined-inline
with the same effect as in Clang, both in C++ and in C.
$ (set -x && cat t.C && clang -S -Wall t.C && gcc -S -Wall t.C)
+ cat t.C
inline int f ();
int g () { return f (); }
+ clang -S -Wall t.C
t.C:1:12: warning: inline function 'f' is not defined [-Wundefined-inline]
inline int f ();
^
t.C:2:19: note: used here
int g () { return f (); }
^
1 warning generated.
+ /build/gcc-master/gcc/xgcc -B /build/gcc-master/gcc -S -Wall t.C
t.C:1:12: warning: inline function ‘int f()’ used but never defined
1 | inline int f ();
| ^
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c/100343] add -Wundefined-inline for inline function is used but not defined
2021-04-29 22:15 [Bug c/100343] New: add -Wundefined-inline for inline function is used but not defined msebor at gcc dot gnu.org
@ 2022-12-27 11:49 ` a.samirh78 at gmail dot com
2022-12-28 19:01 ` pinskia at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: a.samirh78 at gmail dot com @ 2022-12-27 11:49 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100343
Ahmad Samir <a.samirh78 at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |a.samirh78 at gmail dot com
--- Comment #1 from Ahmad Samir <a.samirh78 at gmail dot com> ---
Looks like a duplicate of bug 66918.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c/100343] add -Wundefined-inline for inline function is used but not defined
2021-04-29 22:15 [Bug c/100343] New: add -Wundefined-inline for inline function is used but not defined msebor at gcc dot gnu.org
2022-12-27 11:49 ` [Bug c/100343] " a.samirh78 at gmail dot com
@ 2022-12-28 19:01 ` pinskia at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-12-28 19:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100343
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |DUPLICATE
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Dup of bug 66918.
*** This bug has been marked as a duplicate of bug 66918 ***
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-12-28 19:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-29 22:15 [Bug c/100343] New: add -Wundefined-inline for inline function is used but not defined msebor at gcc dot gnu.org
2022-12-27 11:49 ` [Bug c/100343] " a.samirh78 at gmail dot com
2022-12-28 19:01 ` pinskia at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).