|
From: | Graham J Lee |
Subject: | Re: problems compiling NSAnimation.m |
Date: | Thu, 10 May 2007 14:34:38 +0100 |
On 10 May 2007, at 13:44, Nicola Pero wrote:
Sorry, forgot to put the mailing list in Cc: ThanksIs there a flag we can pass to ask GCC to refuse c99-isms ? There must be one.-std=c89 or -std=gnu89 depending on whether we want to permit GNU C extensions.Nicola answered:Actually, they seem to work -- the problem is that -std=gnu89 is already the standard, but was changed in GCC 3.0 to allow declarations of variables in the middle of code (which are, in this context, a 'GNU extension' borrowedfrom c99). I think what we want is -Wdeclaration-after-statement The problems are:* not sure if that flag is available with GCC 2.95 -- need to check what happens if you use it with GCC 2.95* it generates a warning, not an error Anyway, I'll add that flag to the core libs. Thanks
How about -Werror? That might encourage people to clean up any existing mess too ;-). OTOH it might be a scary amount of mess...
Cheers, Graham.
[Prev in Thread] | Current Thread | [Next in Thread] |