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

ruby-changes:22212

From: nobu <ko1@a...>
Date: Tue, 10 Jan 2012 15:52:36 +0900 (JST)
Subject: [ruby-changes:22212] nobu:r34261 (trunk): * gc.c (HEAP_OBJ_LIMIT): suppress narrowing down warning from gcc 4.2.

nobu	2012-01-10 15:52:24 +0900 (Tue, 10 Jan 2012)

  New Revision: 34261

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

  Log:
    * gc.c (HEAP_OBJ_LIMIT): suppress narrowing down warning from gcc 4.2.

  Modified files:
    trunk/gc.c

Index: gc.c
===================================================================
--- gc.c	(revision 34260)
+++ gc.c	(revision 34261)
@@ -543,7 +543,7 @@
 #define REQUIRED_SIZE_BY_MALLOC (sizeof(size_t) * 5)
 #define HEAP_SIZE (HEAP_ALIGN - REQUIRED_SIZE_BY_MALLOC)
 
-#define HEAP_OBJ_LIMIT (HEAP_SIZE/(unsigned int)sizeof(struct RVALUE) - (unsigned int)(sizeof(struct heaps_slot)/sizeof(struct RVALUE)+1))
+#define HEAP_OBJ_LIMIT (unsigned int)(HEAP_SIZE/sizeof(struct RVALUE) - (sizeof(struct heaps_slot)/sizeof(struct RVALUE)+1))
 #define HEAP_BITMAP_LIMIT (HEAP_OBJ_LIMIT/sizeof(uintptr_t)+1)
 
 #define GET_HEAP_HEADER(x) (HEAP_HEADER(((uintptr_t)x) & ~(HEAP_ALIGN_MASK)))

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

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