diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | proc.c | 5 |
2 files changed, 6 insertions, 3 deletions
@@ -1,3 +1,7 @@ +Sun Jul 21 08:12:16 2013 Kazuki Tsujimoto <kazuki@callcc.net> + + * proc.c (proc_to_s): use PRIsVALUE to preserve the result encoding. + Sun Jul 21 03:36:18 2013 NARUSE, Yui <naruse@ruby-lang.org> * hash.c (rb_hash_flatten): use NUM2INT to raise TypeError on 32bit @@ -883,9 +883,8 @@ proc_to_s(VALUE self) if (iseq->line_info_table) { first_lineno = rb_iseq_first_lineno(iseq); } - str = rb_sprintf("#<%s:%p@%s:%d%s>", cname, (void *)self, - RSTRING_PTR(iseq->location.path), - first_lineno, is_lambda); + str = rb_sprintf("#<%s:%p@%"PRIsVALUE":%d%s>", cname, (void *)self, + iseq->location.path, first_lineno, is_lambda); } else { str = rb_sprintf("#<%s:%p%s>", cname, (void *)proc->block.iseq, |