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

ruby-changes:13167

From: nobu <ko1@a...>
Date: Mon, 14 Sep 2009 10:45:03 +0900 (JST)
Subject: [ruby-changes:13167] Ruby:r24919 (trunk): * include/ruby/ruby.h (RB_TYPE_P): should not use BUILTIN_TYPE for

nobu	2009-09-14 10:44:48 +0900 (Mon, 14 Sep 2009)

  New Revision: 24919

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

  Log:
    * include/ruby/ruby.h (RB_TYPE_P): should not use BUILTIN_TYPE for
      special constants.

  Modified files:
    trunk/ChangeLog
    trunk/include/ruby/ruby.h

Index: include/ruby/ruby.h
===================================================================
--- include/ruby/ruby.h	(revision 24918)
+++ include/ruby/ruby.h	(revision 24919)
@@ -1258,7 +1258,7 @@
 	((type) == T_NIL) ? ((obj) == Qnil) : \
 	((type) == T_UNDEF) ? ((obj) == Qundef) : \
 	((type) == T_SYMBOL) ? SYMBOL_P(obj) : \
-	(BUILTIN_TYPE(obj) == (type)))
+	(!SPECIAL_CONST_P(obj) && BUILTIN_TYPE(obj) == (type)))
 
 #ifdef __GNUC__
 #define rb_type_p(obj, type) \
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 24918)
+++ ChangeLog	(revision 24919)
@@ -1,3 +1,8 @@
+Mon Sep 14 10:44:47 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* include/ruby/ruby.h (RB_TYPE_P): should not use BUILTIN_TYPE for
+	  special constants.
+
 Mon Sep 14 10:08:19 2009  NARUSE, Yui  <naruse@r...>
 
 	* string.c (rb_str_inspect): use rb_enc_mbc_to_codepoint

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

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