declared function array as const.

2005-04-29  Sven Neumann  <sven@gimp.org>

        * tools/pdbgen/enumcode.pl: declared function array as const.

        * libgimp/gimpenums.c.tail: regenerated.
This commit is contained in:
Sven Neumann 2005-04-29 18:29:24 +00:00 committed by Sven Neumann
parent 4ab7e091a9
commit 99a4393cb7
3 changed files with 14 additions and 12 deletions

View file

@ -1,3 +1,9 @@
2005-04-29 Sven Neumann <sven@gimp.org>
* tools/pdbgen/enumcode.pl: declared function array as const.
* libgimp/gimpenums.c.tail: regenerated.
2005-04-29 Sven Neumann <sven@gimp.org>
* app/core/gimpprojection-construct.c (gimp_projection_construct):

View file

@ -1,7 +1,7 @@
typedef GType (* GimpGetTypeFunc) (void);
static GimpGetTypeFunc get_type_funcs[] =
static const GimpGetTypeFunc get_type_funcs[] =
{
gimp_add_mask_type_get_type,
gimp_blend_mode_get_type,
@ -94,12 +94,10 @@ static const gchar *type_names[] =
void
_gimp_enums_init (void)
{
GimpGetTypeFunc *funcs;
gint i;
const GimpGetTypeFunc *funcs = get_type_funcs;
gint i;
for (i = 0, funcs = get_type_funcs;
i < G_N_ELEMENTS (get_type_funcs);
i++, funcs++)
for (i = 0; i < G_N_ELEMENTS (get_type_funcs); i++, funcs++)
{
GType type = (*funcs) ();

View file

@ -117,7 +117,7 @@ print ENUMFILE <<CODE;
typedef GType (* GimpGetTypeFunc) (void);
static GimpGetTypeFunc get_type_funcs[] =
static const GimpGetTypeFunc get_type_funcs[] =
{
CODE
@ -164,12 +164,10 @@ print ENUMFILE <<CODE;
void
_gimp_enums_init (void)
{
GimpGetTypeFunc *funcs;
gint i;
const GimpGetTypeFunc *funcs = get_type_funcs;
gint i;
for (i = 0, funcs = get_type_funcs;
i < G_N_ELEMENTS (get_type_funcs);
i++, funcs++)
for (i = 0; i < G_N_ELEMENTS (get_type_funcs); i++, funcs++)
{
GType type = (*funcs) ();