I'd like to start treating calls to undeclared functions in C as errors,
at least in CI builds. This has long been an error in c++, but is only
a warning with C.
I can easily add this only for the CI jobs w/ GCC with:
> cat <<EOF >> configure/CONFIG_SITE.local
> USR_CFLAGS += -Werror-implicit-function-declaration
> EOF
Note: the newer -Werror=* syntax was added with GCC 4.2. As of 8.3
the older flag is still recognized (thank you GCC).
My question is whether this should become a default for all builds?
(in WARN_CFLAGS_YES?)
My inclination is yes. I've certainly never intended to rely on an implicit
declaration, but have occasionally done so unwittingly as a result of
a missing #include.
- Replies:
- Re: -Werror=implicit-function-declaration by default? Johnson, Andrew N. via Core-talk
- Navigate by Date:
- Prev:
Re: [Merge] ~dirk.zimoch/epics-base:epicsMutexPriorityInheritance into epics-base:7.0 mdavidsaver via Core-talk
- Next:
Build failed: EPICS Base 3.15 base-3.15-27 AppVeyor via Core-talk
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
<2020>
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Build failed: EPICS Base 3.15 base-3.15-26 AppVeyor via Core-talk
- Next:
Re: -Werror=implicit-function-declaration by default? Johnson, Andrew N. via Core-talk
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
<2020>
2021
2022
2023
2024
|