Re: g_slist and const



Asbjørn wrote:

> I use C++/glib and i get this  strange looking function:
> 
> guint my_class::length (const GSList  *list)  /* const to protect my list */
> {
>    /* cast it to a non const pointer! */
>     return (g_slist_length  ((GSList *) list)); 
> }
> 
> So i want glib "C" to be more "C++" friendly    :)

Just use Glibmm.


Hub



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