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

ruby-changes:2071

From: ko1@a...
Date: 29 Sep 2007 09:14:10 +0900
Subject: [ruby-changes:2071] akr - Ruby:r13562 (trunk): * object.c (rb_class_real): use BUILTIN_TYPE instead of TYPE.

akr	2007-09-29 09:13:58 +0900 (Sat, 29 Sep 2007)

  New Revision: 13562

  Modified files:
    trunk/ChangeLog
    trunk/object.c

  Log:
    * object.c (rb_class_real): use BUILTIN_TYPE instead of TYPE.
      access flags directly intead of FL_TEST.
      they are enough because cl argument is a class.


  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/ChangeLog?r1=13562&r2=13561
  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/object.c?r1=13562&r2=13561

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 13561)
+++ ChangeLog	(revision 13562)
@@ -1,3 +1,9 @@
+Sat Sep 29 09:12:02 2007  Tanaka Akira  <akr@f...>
+
+	* object.c (rb_class_real): use BUILTIN_TYPE instead of TYPE.
+	  access flags directly intead of FL_TEST.
+	  they are enough because cl argument is a class.
+
 Sat Sep 29 08:57:15 2007  Nobuyoshi Nakada  <nobu@r...>
 
 	* include/ruby/win32.h (strcasecmp): needed for type_strcasehash.
Index: object.c
===================================================================
--- object.c	(revision 13561)
+++ object.c	(revision 13562)
@@ -99,7 +99,7 @@
 VALUE
 rb_class_real(VALUE cl)
 {
-    while (FL_TEST(cl, FL_SINGLETON) || TYPE(cl) == T_ICLASS) {
+    while ((RBASIC(cl)->flags & FL_SINGLETON) || BUILTIN_TYPE(cl) == T_ICLASS) {
 	cl = RCLASS_SUPER(cl);
     }
     return cl;

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

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