summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-09-19 01:46:42 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-09-19 01:46:42 +0000
commit8b9afe6520eddc81c7edb1328f1543e9df7fea2f (patch)
tree05126011f066f29f06dea0c31075414b9d437e41 /include
parentd9a597408f0f192ff25ab51e1e6733fe6fefc01b (diff)
error.c: preserve encoding
* error.c (rb_error_frozen_object): preserve encoding of class name in error message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47634 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r--include/ruby/intern.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/ruby/intern.h b/include/ruby/intern.h
index 1517023..ecb4ba7 100644
--- a/include/ruby/intern.h
+++ b/include/ruby/intern.h
@@ -255,13 +255,14 @@ PRINTF_ARGS(void rb_compile_error(const char*, int, const char*, ...), 3, 4);
PRINTF_ARGS(void rb_compile_error_with_enc(const char*, int, void *, const char*, ...), 4, 5);
PRINTF_ARGS(void rb_compile_error_append(const char*, ...), 1, 2);
NORETURN(void rb_error_frozen(const char*));
+NORETURN(void rb_error_frozen_object(VALUE));
void rb_error_untrusted(VALUE);
void rb_check_frozen(VALUE);
void rb_check_trusted(VALUE);
#define rb_check_frozen_internal(obj) do { \
VALUE frozen_obj = (obj); \
if (OBJ_FROZEN(frozen_obj)) { \
- rb_error_frozen(rb_obj_classname(frozen_obj)); \
+ rb_error_frozen_object(frozen_obj); \
} \
} while (0)
#define rb_check_trusted_internal(obj) ((void) 0)