aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1995-05-16 17:46:42 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1995-05-16 17:46:42 -0400
commit2b61d00a8b7d74027dcfde0010711494af822f7e (patch)
tree700420a6aa5215dd773ef8de0cd0735965e2bd2e
parent2c89fb2e667691049f673f2429889e90834667c8 (diff)
downloadgcc-2b61d00a8b7d74027dcfde0010711494af822f7e.zip
gcc-2b61d00a8b7d74027dcfde0010711494af822f7e.tar.gz
gcc-2b61d00a8b7d74027dcfde0010711494af822f7e.tar.bz2
(sarray_realloc): Make array index variables size_t.
From-SVN: r9721
-rw-r--r--gcc/objc/sarray.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/gcc/objc/sarray.c b/gcc/objc/sarray.c
index 78f5339..c22bc30 100644
--- a/gcc/objc/sarray.c
+++ b/gcc/objc/sarray.c
@@ -1,5 +1,5 @@
/* Sparse Arrays for Objective C dispatch tables
- Copyright (C) 1993 Free Software Foundation, Inc.
+ Copyright (C) 1993, 1995 Free Software Foundation, Inc.
This file is part of GNU CC.
@@ -218,14 +218,14 @@ void
sarray_realloc(struct sarray* array, int newsize)
{
#ifdef OBJC_SPARSE3
- int old_max_index = (array->capacity-1)/INDEX_CAPACITY;
- int new_max_index = ((newsize-1)/INDEX_CAPACITY);
- int rounded_size = (new_max_index+1)*INDEX_CAPACITY;
+ size_t old_max_index = (array->capacity-1)/INDEX_CAPACITY;
+ size_t new_max_index = ((newsize-1)/INDEX_CAPACITY);
+ size_t rounded_size = (new_max_index+1)*INDEX_CAPACITY;
#else /* OBJC_SPARSE2 */
- int old_max_index = (array->capacity-1)/BUCKET_SIZE;
- int new_max_index = ((newsize-1)/BUCKET_SIZE);
- int rounded_size = (new_max_index+1)*BUCKET_SIZE;
+ size_t old_max_index = (array->capacity-1)/BUCKET_SIZE;
+ size_t new_max_index = ((newsize-1)/BUCKET_SIZE);
+ size_t rounded_size = (new_max_index+1)*BUCKET_SIZE;
#endif