Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Joseph Myers
On Fri, 20 May 2016, Andrew Haley wrote: > Given this, I do not understand why GCC does not treat implicit int as > a hard error. Because in C the existing practice has been that we support the union of all features and extensions that can sensibly be supported with the given language version (

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Joseph Myers
On Fri, 20 May 2016, Jeff Law wrote: > I think it's worth revisiting as well, burying in -pedantic seems wrong given > the kinds of failures we can see. It's not in -pedantic. The warnings are on by default for C99/C11 (and become errors with -pedantic-errors or the -Werror= options). -- Jose

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Jeff Law
On 05/20/2016 03:24 AM, Florian Weimer wrote: On 05/20/2016 11:22 AM, Andreas Schwab wrote: Florian Weimer writes: C99 got rid of implicit function definitions and implicit ints. Would it be possible to remove them retroactively from the -std=gnu99 and -std=gnu11 language variants (as well as

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Florian Weimer
On 05/20/2016 11:22 AM, Andreas Schwab wrote: Florian Weimer writes: C99 got rid of implicit function definitions and implicit ints. Would it be possible to remove them retroactively from the -std=gnu99 and -std=gnu11 language variants (as well as -std=c99 and -std=c11), so that they are reje

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Andreas Schwab
Florian Weimer writes: > C99 got rid of implicit function definitions and implicit ints. Would it > be possible to remove them retroactively from the -std=gnu99 and > -std=gnu11 language variants (as well as -std=c99 and -std=c11), so that > they are rejected by default? -Werror=implicit-int -W

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Andrew Haley
On 05/20/2016 10:02 AM, Florian Weimer wrote: > On 05/20/2016 10:30 AM, lh mouse wrote: >> Implicit function declarations result in warnings since C99 or GNU99 and >> '-pedantic-errors' turns them into errors. >> The same goes for implicit return types. > > The warnings typically do not stop the

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread Florian Weimer
On 05/20/2016 10:30 AM, lh mouse wrote: Implicit function declarations result in warnings since C99 or GNU99 and '-pedantic-errors' turns them into errors. The same goes for implicit return types. The warnings typically do not stop the build, and thus are not really helpful when you are looki

Re: GNU C: Implicit int and implicit function definitions

2016-05-20 Thread lh mouse
Implicit function declarations result in warnings since C99 or GNU99 and '-pedantic-errors' turns them into errors. The same goes for implicit return types. -- Best regards, lh_mouse 2016-05-20 --