This is the mail archive of the
mailing list for the GCC project.
RE: need help
- From: "Jon Beniston" <jbeniston at compxs dot com>
- To: "'Eitan'" <eitangur at bezeqint dot net>, <gcc at gcc dot gnu dot org>, <gcc-help at gcc dot gnu dot org>
- Date: Fri, 26 Sep 2003 12:32:54 +0100
- Subject: RE: need help
- Organization: CompXs
- Reply-to: <jbeniston at compxs dot com>
> 2. I get an annoying warning message - "warning: too many
> arguments for format". What does it mean?
Probably that you're doing something like
printf("%s %d\n", name, age, address);
i.e. there are more arguments than there are %'s.
> 3. Good programing parctice - If I have a static global
> variable, that is defined in one file, but not used in it -
> why is it a bad thing (I get a warning)?
Static variables (and functions) are not visible to other files. So if
they're not referenced in the file in which they are defined, then they
may as well not exist.