/* Specifies the type of functions passed to g_list_foreach() and g_slist_foreach().  */
void g_list_foreach(GList *list, GFunc func, gpointer user_data)
/* Specifies the type of functions passed to g_list_foreach() and g_slist_foreach().  */
void g_list_foreach(GList *list, GFunc func, gpointer user_data)
{
  while (list)
    {
      GList *next = list->next;
      (*func) (list->data, user_data);
      list = next;
    }
}