[前][次][番号順一覧][スレッド一覧]

ruby-changes:11298

From: nobu <ko1@a...>
Date: Thu, 12 Mar 2009 17:56:45 +0900 (JST)
Subject: [ruby-changes:11298] Ruby:r22911 (trunk): * st.c: use st_index_t for indexes instead of int.

nobu	2009-03-12 17:56:31 +0900 (Thu, 12 Mar 2009)

  New Revision: 22911

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=22911

  Log:
    * st.c: use st_index_t for indexes instead of int.

  Modified files:
    trunk/ChangeLog
    trunk/st.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 22910)
+++ ChangeLog	(revision 22911)
@@ -1,3 +1,7 @@
+Thu Mar 12 17:56:29 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* st.c: use st_index_t for indexes instead of int.
+
 Thu Mar 12 09:30:54 2009  Nobuyoshi Nakada  <nobu@r...>
 
 	* configure.in (RUBY_CHECK_SIZEOF): if same size type is found, no
Index: st.c
===================================================================
--- st.c	(revision 22910)
+++ st.c	(revision 22911)
@@ -227,7 +227,7 @@
 st_clear(st_table *table)
 {
     register st_table_entry *ptr, *next;
-    int i;
+    st_index_t i;
 
     if (table->entries_packed) {
         table->num_entries = 0;
@@ -284,7 +284,7 @@
     register st_table_entry *ptr;
 
     if (table->entries_packed) {
-        int i;
+        st_index_t i;
         for (i = 0; i < table->num_entries; i++) {
             if ((st_data_t)table->bins[i*2] == key) {
                 if (value !=0) *value = (st_data_t)table->bins[i*2+1];
@@ -313,7 +313,7 @@
     register st_table_entry *ptr;
 
     if (table->entries_packed) {
-        int i;
+        st_index_t i;
         for (i = 0; i < table->num_entries; i++) {
             if ((st_data_t)table->bins[i*2] == key) {
                 if (result !=0) *result = (st_data_t)table->bins[i*2];
@@ -385,7 +385,7 @@
     register st_table_entry *ptr;
 
     if (table->entries_packed) {
-        int i;
+        st_index_t i;
         for (i = 0; i < table->num_entries; i++) {
             if ((st_data_t)table->bins[i*2] == key) {
                 table->bins[i*2+1] = (struct st_table_entry*)value;
@@ -536,7 +536,7 @@
     register st_table_entry *ptr;
 
     if (table->entries_packed) {
-        int i;
+        st_index_t i;
         for (i = 0; i < table->num_entries; i++) {
             if ((st_data_t)table->bins[i*2] == *key) {
                 if (value != 0) *value = (st_data_t)table->bins[i*2+1];
@@ -594,7 +594,7 @@
 st_cleanup_safe(st_table *table, st_data_t never)
 {
     st_table_entry *ptr, **last, *tmp;
-    int i;
+    st_index_t i;
 
     for (i = 0; i < table->num_bins; i++) {
 	ptr = *(last = &table->bins[i]);
@@ -616,11 +616,11 @@
 {
     st_table_entry *ptr, **last, *tmp;
     enum st_retval retval;
-    int i;
+    st_index_t i;
 
     if (table->entries_packed) {
         for (i = 0; i < table->num_entries; i++) {
-            int j;
+            st_index_t j;
             st_data_t key, val;
             key = (st_data_t)table->bins[i*2];
             val = (st_data_t)table->bins[i*2+1];

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]