+2007-07-26 Jakub Jelinek <jakub@redhat.com>
+
+ * gettextP.h (struct loaded_domain): Change plural to const
+ struct expression *.
+ * eval-plural.h (plural_eval): Change first argument to
+ const struct expression *.
+ * plural-exp.c (EXTRACT_PLURAL_EXPRESSION): Change first argument to
+ const struct expression **.
+ * plural-exp.h (EXTRACT_PLURAL_EXPRESSION, plural_eval): Adjust
+ prototypes.
+ * loadmsgcat.c (_nl_unload_domain): Cast away const in call to
+ __gettext_free_exp.
+
2007-07-19 Jakub Jelinek <jakub@redhat.com>
* dcigettext.c (_nl_find_msg): Return NULL even if __gconv_open
/* Plural expression evaluation.
- Copyright (C) 2000-2003 Free Software Foundation, Inc.
+ Copyright (C) 2000-2003, 2007 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published
STATIC
unsigned long int
internal_function
-plural_eval (struct expression *pexp, unsigned long int n)
+plural_eval (const struct expression *pexp, unsigned long int n)
{
switch (pexp->nargs)
{
struct converted_domain *conversions;
size_t nconversions;
- struct expression *plural;
+ const struct expression *plural;
unsigned long int nplurals;
};
/* Load needed message catalogs.
- Copyright (C) 1995-1999, 2000-2006 Free Software Foundation, Inc.
+ Copyright (C) 1995-1999, 2000-2007 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published
size_t i;
if (domain->plural != &__gettext_germanic_plural)
- __gettext_free_exp (domain->plural);
+ __gettext_free_exp ((struct expression *) domain->plural);
for (i = 0; i < domain->nconversions; i++)
{
/* Expression parsing for plural form selection.
- Copyright (C) 2000-2001, 2003, 2005-2006 Free Software Foundation, Inc.
+ Copyright (C) 2000-2001, 2003, 2005-2007 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
This program is free software; you can redistribute it and/or modify it
void
internal_function
-EXTRACT_PLURAL_EXPRESSION (const char *nullentry, struct expression **pluralp,
+EXTRACT_PLURAL_EXPRESSION (const char *nullentry,
+ const struct expression **pluralp,
unsigned long int *npluralsp)
{
if (nullentry != NULL)
/* Expression parsing and evaluation for plural form selection.
- Copyright (C) 2000-2003, 2005-2006 Free Software Foundation, Inc.
+ Copyright (C) 2000-2003, 2005-2007 Free Software Foundation, Inc.
Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
This program is free software; you can redistribute it and/or modify it
extern int PLURAL_PARSE (void *arg);
extern struct expression GERMANIC_PLURAL attribute_hidden;
extern void EXTRACT_PLURAL_EXPRESSION (const char *nullentry,
- struct expression **pluralp,
+ const struct expression **pluralp,
unsigned long int *npluralsp)
internal_function;
#if !defined (_LIBC) && !defined (IN_LIBINTL) && !defined (IN_LIBGLOCALE)
-extern unsigned long int plural_eval (struct expression *pexp,
+extern unsigned long int plural_eval (const struct expression *pexp,
unsigned long int n);
#endif