Re: (patch) clist/ctree const-ness




On Sat, 16 Jan 1999, Jeff Garzik wrote:
> > On Sat, 16 Jan 1999, Jeff Garzik wrote:
> > 
> > > Will commit the patch below unless there are objections; it makes the
> > > clist_new_with_titles and related functions const-correct.
> > 
> > please don't do this, const gchar** is very different from const gchar*
> > as the compiler won't automatically convert the pointer. look into the
> > archives (or the ChangeLog), we've had that about 2 or 3 times already.
> 
> 
> I was afraid of that, which is why I posted the patch for comment :)  Is
> there any way to achieve the desired effect?  I am trying to kill the
> warnings that occur in app code related to *_new_with_titles().
> 

No there's no way to avoid warnings here. If you make _new_with_titles()
correct, then stuffing a gchar** into it causes warnings; if you leave it
as is, stuffing a const gchar** into it causes warnings. Someone gets the
warnings.

(I keep arguing that gchar** should get the warnings, but Tim doesn't
agree with me. ;-)

BTW, does this list *have* archives? There is no link from www.gtk.org.

Havoc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]