* src/symlist.c (symbol_list_length): Return int, not unsigned

int, since callers expect int.
This commit is contained in:
Paul Eggert
2006-07-09 19:55:15 +00:00
parent 08bc001306
commit b37acfe18c
2 changed files with 5 additions and 5 deletions

View File

@@ -100,8 +100,8 @@ symbol_list_free (symbol_list *list)
| Return its length. | | Return its length. |
`--------------------*/ `--------------------*/
unsigned int int
symbol_list_length (const symbol_list *l) symbol_list_length (symbol_list const *l)
{ {
int res = 0; int res = 0;
for (/* Nothing. */; l && l->sym; l = l->next) for (/* Nothing. */; l && l->sym; l = l->next)

View File

@@ -1,6 +1,6 @@
/* Lists of symbols for Bison /* Lists of symbols for Bison
Copyright (C) 2002, 2005 Free Software Foundation, Inc. Copyright (C) 2002, 2005, 2006 Free Software Foundation, Inc.
This file is part of Bison, the GNU Compiler Compiler. This file is part of Bison, the GNU Compiler Compiler.
@@ -76,7 +76,7 @@ symbol_list *symbol_list_prepend (symbol_list *l,
void symbol_list_free (symbol_list *l); void symbol_list_free (symbol_list *l);
/* Return its length. */ /* Return its length. */
unsigned int symbol_list_length (const symbol_list *l); int symbol_list_length (symbol_list const *l);
/* Get symbol N in symbol list L. */ /* Get symbol N in symbol list L. */
symbol_list *symbol_list_n_get (symbol_list *l, int n); symbol_list *symbol_list_n_get (symbol_list *l, int n);