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

ruby-changes:39600

From: nobu <ko1@a...>
Date: Wed, 26 Aug 2015 09:47:08 +0900 (JST)
Subject: [ruby-changes:39600] nobu:r51681 (trunk): id_table.c: adjust indent

nobu	2015-08-26 09:46:58 +0900 (Wed, 26 Aug 2015)

  New Revision: 51681

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

  Log:
    id_table.c: adjust indent
    
    * id_table.c (list_table_extend, fix_empty): adjust indent.
      (hash_id_table_foreach_values): ditto.

  Modified files:
    trunk/id_table.c
Index: id_table.c
===================================================================
--- id_table.c	(revision 51680)
+++ id_table.c	(revision 51681)
@@ -427,15 +427,15 @@ list_table_extend(struct list_id_table * https://github.com/ruby/ruby/blob/trunk/id_table.c#L427
 		}
 
 		if (0)
-		  for (i=0; i< 2 * num; i++) {
-		    unsigned char *cs = (unsigned char *)&tbl->keys[i];
-		    size_t j;
-		    fprintf(stderr, ">> %3d | %p - ", i, cs);
-		    for (j=0; j<sizeof(VALUE); j++) {
-			fprintf(stderr, "%x ", cs[j]);
+		    for (i=0; i< 2 * num; i++) {
+			unsigned char *cs = (unsigned char *)&tbl->keys[i];
+			size_t j;
+			fprintf(stderr, ">> %3d | %p - ", i, cs);
+			for (j=0; j<sizeof(VALUE); j++) {
+			    fprintf(stderr, "%x ", cs[j]);
+			}
+			fprintf(stderr, "\n");
 		    }
-		    fprintf(stderr, "\n");
-		  }
 	    }
 
 	    tbl->keys = (id_key_t *)xrealloc(tbl->keys, size);
@@ -812,8 +812,8 @@ calc_pos(register sa_table* table, id_ke https://github.com/ruby/ruby/blob/trunk/id_table.c#L812
 static void
 fix_empty(register sa_table* table)
 {
-    while(--table->free_pos &&
-            table->entries[table->free_pos-1].next != SA_EMPTY);
+    while (--table->free_pos &&
+	   table->entries[table->free_pos-1].next != SA_EMPTY);
 }
 
 #define FLOOR_TO_4 ((~((sa_index_t)0)) << 2)
@@ -1008,7 +1008,7 @@ hash_id_table_lookup(register sa_table * https://github.com/ruby/ruby/blob/trunk/id_table.c#L1008
         if (entry->key == key) goto found;
     }
     return 0;
-found:
+  found:
     if (valuep) *valuep = entry->value;
     return 1;
 }
@@ -1058,7 +1058,7 @@ hash_id_table_delete(sa_table *table, ID https://github.com/ruby/ruby/blob/trunk/id_table.c#L1058
         entry = table->entries + pos;
     } while(1);
 
-not_found:
+  not_found:
     return 0;
 }
 
@@ -1382,7 +1382,7 @@ hash_id_table_foreach_values(struct hash https://github.com/ruby/ruby/blob/trunk/id_table.c#L1382
 	    enum rb_id_table_iterator_result ret = (*func)(tbl->items[i].val, data);
 
 	    if (ret == ID_TABLE_DELETE)
-	      hash_delete_index(tbl, i);
+		hash_delete_index(tbl, i);
 	    else if (ret == ID_TABLE_STOP)
 		return;
 	}

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

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