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

ruby-changes:31731

From: tmm1 <ko1@a...>
Date: Sat, 23 Nov 2013 09:46:30 +0900 (JST)
Subject: [ruby-changes:31731] tmm1:r43810 (trunk): * marshal.c (w_object): Use HASH_PROC_DEFAULT directly from internal.h

tmm1	2013-11-23 09:46:25 +0900 (Sat, 23 Nov 2013)

  New Revision: 43810

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

  Log:
    * marshal.c (w_object): Use HASH_PROC_DEFAULT directly from internal.h

  Modified files:
    trunk/ChangeLog
    trunk/marshal.c
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 43809)
+++ ChangeLog	(revision 43810)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Sat Nov 23 09:45:49 2013  Aman Gupta <ruby@t...>
+
+	* marshal.c (w_object): Use HASH_PROC_DEFAULT directly from internal.h
+
 Sat Nov 23 08:43:23 2013  Aman Gupta <ruby@t...>
 
 	* gc.c: Rename heap_pages_swept_num to heap_pages_swept_slots to
Index: marshal.c
===================================================================
--- marshal.c	(revision 43809)
+++ marshal.c	(revision 43810)
@@ -797,8 +797,7 @@ w_object(VALUE obj, struct dump_arg *arg https://github.com/ruby/ruby/blob/trunk/marshal.c#L797
 	    if (NIL_P(RHASH_IFNONE(obj))) {
 		w_byte(TYPE_HASH, arg);
 	    }
-	    else if (FL_TEST(obj, FL_USER2)) {
-		/* FL_USER2 means HASH_PROC_DEFAULT (see hash.c) */
+	    else if (FL_TEST(obj, HASH_PROC_DEFAULT)) {
 		rb_raise(rb_eTypeError, "can't dump hash with default proc");
 	    }
 	    else {

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

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