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

ruby-changes:27830

From: nobu <ko1@a...>
Date: Sat, 23 Mar 2013 17:46:54 +0900 (JST)
Subject: [ruby-changes:27830] nobu:r39882 (trunk): * array.c (take_items): honor encoding of class name.

nobu	2013-03-23 17:45:32 +0900 (Sat, 23 Mar 2013)

  New Revision: 39882

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

  Log:
    * array.c (take_items): honor encoding of class name.

  Modified files:
    trunk/array.c

Index: array.c
===================================================================
--- array.c	(revision 39881)
+++ array.c	(revision 39882)
@@ -3050,8 +3050,8 @@ take_items(VALUE obj, long n) https://github.com/ruby/ruby/blob/trunk/array.c#L3050
     result = rb_ary_new2(n);
     args[0] = result; args[1] = (VALUE)n;
     if (rb_check_block_call(obj, idEach, 0, 0, take_i, (VALUE)args) == Qundef)
-        rb_raise(rb_eTypeError, "wrong argument type %s (must respond to :each)",
-            rb_obj_classname(obj));
+	rb_raise(rb_eTypeError, "wrong argument type %"PRIsVALUE" (must respond to :each)",
+		 rb_obj_class(obj));
     return result;
 }
 

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

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