summaryrefslogtreecommitdiffhomepage
path: root/src/string.c
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2017-12-12 18:41:18 +0900
committerYukihiro "Matz" Matsumoto <[email protected]>2017-12-12 18:41:18 +0900
commitbbb088234395efda23540d30ab5d1cb40f220d82 (patch)
tree4f66588878264c0d2a17529629d7d183d6a49d29 /src/string.c
parentd4ff92bcf65ce140495014f40d22b93a1b1fb957 (diff)
downloadmruby-bbb088234395efda23540d30ab5d1cb40f220d82.tar.gz
mruby-bbb088234395efda23540d30ab5d1cb40f220d82.zip
Modifying frozen objects will raise `FrozenError`.
`FrozenError` is a subclass of `RuntimeError` which used to be raised. [Ruby2.5]
Diffstat (limited to 'src/string.c')
-rw-r--r--src/string.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/string.c b/src/string.c
index da475839c..d4dc517cf 100644
--- a/src/string.c
+++ b/src/string.c
@@ -494,7 +494,7 @@ static void
check_frozen(mrb_state *mrb, struct RString *s)
{
if (MRB_FROZEN_P(s)) {
- mrb_raise(mrb, E_RUNTIME_ERROR, "can't modify frozen string");
+ mrb_raise(mrb, E_FROZEN_ERROR, "can't modify frozen string");
}
}