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

ruby-changes:38226

From: nobu <ko1@a...>
Date: Tue, 14 Apr 2015 12:33:28 +0900 (JST)
Subject: [ruby-changes:38226] nobu:r50307 (trunk): vm_backtrace.c: use rb_id2str

nobu	2015-04-14 12:33:00 +0900 (Tue, 14 Apr 2015)

  New Revision: 50307

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

  Log:
    vm_backtrace.c: use rb_id2str
    
    * vm_backtrace.c (location_base_label): convert ID to string
      directly, and the return value is frozen.

  Modified files:
    trunk/vm_backtrace.c
Index: vm_backtrace.c
===================================================================
--- vm_backtrace.c	(revision 50306)
+++ vm_backtrace.c	(revision 50307)
@@ -208,7 +208,7 @@ location_base_label(rb_backtrace_locatio https://github.com/ruby/ruby/blob/trunk/vm_backtrace.c#L208
       case LOCATION_TYPE_ISEQ_CALCED:
 	return loc->body.iseq.iseq->location.base_label;
       case LOCATION_TYPE_CFUNC:
-	return rb_sym_to_s(ID2SYM(loc->body.cfunc.mid));
+	return rb_id2str(loc->body.cfunc.mid);
       case LOCATION_TYPE_IFUNC:
       default:
 	rb_bug("location_base_label: unreachable");

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

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