diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-06-28 17:06:59 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-06-28 17:06:59 +0000 |
commit | 491ace2dbebcba5e6f36b9e877c585823fd583f1 (patch) | |
tree | 4aa082d64367ae2005f212fcc10bf3cb3843ba2c /insns.def | |
parent | 3ed6f43b96de41f57edbb4c935f58342b12996f5 (diff) | |
download | ruby-491ace2dbebcba5e6f36b9e877c585823fd583f1.tar.gz |
insns.def: preserve encoding
* insns.def (defineclass): preserve encoding of name in error
messages when already defined but type mismatch.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'insns.def')
-rw-r--r-- | insns.def | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -861,7 +861,7 @@ defineclass klass = VM_DEFINECLASS_SCOPED_P(flags) ? rb_public_const_get_at(klass, id) : rb_const_get_at(klass, id); if (!RB_TYPE_P(klass, T_CLASS)) { - rb_raise(rb_eTypeError, "%s is not a class", rb_id2name(id)); + rb_raise(rb_eTypeError, "% "PRIsVALUE" is not a class", rb_id2str(id)); } if (super != rb_cObject) { @@ -899,7 +899,7 @@ defineclass rb_public_const_get_at(klass, id) : rb_const_get_at(klass, id); /* already exist */ if (!RB_TYPE_P(klass, T_MODULE)) { - rb_raise(rb_eTypeError, "%s is not a module", rb_id2name(id)); + rb_raise(rb_eTypeError, "% "PRIsVALUE" is not a module", rb_id2str(id)); } } else { |