[Gnucash-changes] r14287 - gnucash/trunk -

Chris Shoemaker c.shoemaker at cox.net
Thu Jun 1 19:56:33 EDT 2006


On Thu, Jun 01, 2006 at 04:44:20PM -0400, Derek Atkins wrote:
> Andreas Köhler <andi5 at cvs.gnucash.org> writes:
> 
> > +static GtkWidget *
> > +gnc_prefs_find_page (GtkNotebook *notebook, const gchar *name)
> >  {
> > -  struct find_data *location;
> > -  const gchar *child_tabname;
> > -  gint index;
> > +  int n_pages;
> > +  GtkWidget *child;
> > +  const gchar *child_name;
> [snip]
> > +
> > +  for (int i=0; i<n_pages; i++) {
> 
> Uhh, this isn't a legal C99 construct.  I think you've been heads-down
> in C++ too much.

But it is.  Problem is, we don't declare our dependence on c99, but we
use its constructs all over the place.  Compilers are free to not
support what we don't declare.

I think we should either stick with -c89 -pedantic, or just accept
-c99.  Otherwise, we're left the whim of whatever c99 features the
compiler wants to offer without warning.

I don't think our internal libraries would compile with -c89
-pedantic, so declaring -c99 would be far easier.

... or we could just continue to fix it up whenever a less liberal
compiler complains.

-chris


More information about the gnucash-devel mailing list