Re: glib constness



Mathieu Lacage <mathieu@eazel.com> writes:

> hi all, 
> 
> Would you accept patches to add const parameters to some 
> g_slist_* calls for glib-2.0 ?
> 
> g_slist_length pops out of my head as an example.

Probably, it would do no harm. 

Though note - I really wouldn't want to recommend using
const GSList * in applications, since I don't think
constness can be represented very well in the way 
GSList works.

 const GSList *list = some_list;
 GSList *next_node = list->next;

Regards,
                                        Owen







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