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

ruby-changes:26785

From: nobu <ko1@a...>
Date: Tue, 15 Jan 2013 23:07:33 +0900 (JST)
Subject: [ruby-changes:26785] nobu:r38837 (trunk): object.c: two literals

nobu	2013-01-15 23:07:22 +0900 (Tue, 15 Jan 2013)

  New Revision: 38837

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

  Log:
    object.c: two literals
    
    * object.c (rb_mod_to_s): concatenate two literals.

  Modified files:
    trunk/object.c

Index: object.c
===================================================================
--- object.c	(revision 38836)
+++ object.c	(revision 38837)
@@ -1349,10 +1349,9 @@ rb_mod_to_s(VALUE klass) https://github.com/ruby/ruby/blob/trunk/object.c#L1349
     VALUE refined_class, defined_at;
 
     if (FL_TEST(klass, FL_SINGLETON)) {
-	VALUE s = rb_usascii_str_new2("#<");
+	VALUE s = rb_usascii_str_new2("#<Class:");
 	VALUE v = rb_iv_get(klass, "__attached__");
 
-	rb_str_cat2(s, "Class:");
 	switch (TYPE(v)) {
 	  case T_CLASS: case T_MODULE:
 	    rb_str_append(s, rb_inspect(v));

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

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