Re: GCC Warning Options
Re: GCC Warning Options
- Subject: Re: GCC Warning Options
- From: Chris Espinosa <email@hidden>
- Date: Fri, 17 Jun 2005 11:57:41 -0700
On Jun 17, 2005, at 11:09 AM, Lawrence Gold wrote: In my CodeWarrior port I'm getting a lot of warnings "missing braces around initializer" for lines like CGRect r = {0,0,0,0} (instead of {{0,0},{0,0}}). Apparently GCC-4 is more strict about this than CW. My inclination is to turn this off to cut down the noise so I can concentrate on more significant warnings.
The odd thing is in both the project and target settings the "Initializer Not Fully Bracketed" warning is turned off (by default apparently). The target's "Other Warning Flags" field does contain the string "-Wmost -Wno-four-char-constants -Wno-unknown-pragmas -Wl,-w", but I have no idea what these mean and I can't find any documentation on them.
Can anybody tell me how to turn off this particular warning, or at least point me to the GCC-4 documentation?
I'd guess that removing -Wmost will eliminate the warning.
FWIW, I find it disturbing that a Macintosh IDE would expose this type of command line UI by default. It's probably okay for obscure cases but since these are default values there should be a better UI for them. For example, the checkbox for "Four Character Literals" is checked, but I also have a command line option "-Wno-four-char-constants". Perhaps these reinforce each other or cancel each other out, I have no idea. The same is true of the unknown pragma case.
I think the "Other Warning Flags" field is filled in by the CodeWarrior -> Xcode importer, which is probably a little out-of-date with respect to the warnings that can be enabled and disabled with checkboxes.
Lawrence is right on both counts; the "Other Warning Flags" options are a hangover from olden times when we didn't have checkboxes for these warnings. You may delete the Other Warning Flags entry and use the checkboxes as you desire.
Chris |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden