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

ruby-changes:34253

From: nobu <ko1@a...>
Date: Tue, 3 Jun 2014 16:44:26 +0900 (JST)
Subject: [ruby-changes:34253] nobu:r46334 (trunk): gc.c: int for simple predicates

nobu	2014-06-03 16:44:19 +0900 (Tue, 03 Jun 2014)

  New Revision: 46334

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

  Log:
    gc.c: int for simple predicates
    
    * gc.c: use int for simple predicate functions instead of VALUE.

  Modified files:
    trunk/gc.c
Index: gc.c
===================================================================
--- gc.c	(revision 46333)
+++ gc.c	(revision 46334)
@@ -766,21 +766,21 @@ check_gen_consistency(VALUE obj) https://github.com/ruby/ruby/blob/trunk/gc.c#L766
     return obj;
 }
 
-static inline VALUE
+static inline int
 RVALUE_INFANT_P(VALUE obj)
 {
     check_gen_consistency(obj);
     return !FL_TEST2(obj, FL_PROMOTED);
 }
 
-static inline VALUE
+static inline int
 RVALUE_OLD_BITMAP_P(VALUE obj)
 {
     check_gen_consistency(obj);
     return (RVALUE_OLDGEN_BITMAP(obj) != 0);
 }
 
-static inline VALUE
+static inline int
 RVALUE_OLD_P(VALUE obj)
 {
     check_gen_consistency(obj);
@@ -791,7 +791,7 @@ RVALUE_OLD_P(VALUE obj) https://github.com/ruby/ruby/blob/trunk/gc.c#L791
 #endif
 }
 
-static inline VALUE
+static inline int
 RVALUE_PROMOTED_P(VALUE obj)
 {
     check_gen_consistency(obj);
@@ -837,7 +837,7 @@ RVALUE_PROMOTE_INFANT(rb_objspace_t *obj https://github.com/ruby/ruby/blob/trunk/gc.c#L837
  * Age1 promotion: Infant (0) -> Old (1 and later).
  * Age2 promotion: Infant (0) -> Young (1) -> Old (2 and later).
  */
-static inline VALUE
+static inline int
 RVALUE_YOUNG_P(VALUE obj)
 {
     check_gen_consistency(obj);

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

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