missing consts in prototypes?
- From: Martin Kahlert <martin kahlert mchp siemens de>
- To: <gtk-list redhat com>
- Subject: missing consts in prototypes?
- Date: Wed, 24 Nov 1999 07:50:24 +0100
Hi,
why can't i do this:
const char *text = g_strdup("Anything");
GtkWidget *leaf = gtk_tree_item_new_with_label(text);
or
GtkWidget *leaf = gtk_tree_item_new_with_label(text);
Both functions have prototypes to accept gchar *.
Wouldn't it be better to changed that to const gchar* ?
gcc -Wall produces warnings otherwise.
If these functions really change their argument,
you will get a lot of trouble with from
gtk_tree_item_new_with_label("hello").
Thanks,
Martin.
--
The early bird gets the worm. If you want something else for
breakfast, get up later.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]