summaryrefslogtreecommitdiffhomepage
path: root/src/string.c
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2014-01-07 15:36:18 -0800
committerYukihiro "Matz" Matsumoto <[email protected]>2014-01-07 15:36:18 -0800
commit2040347d26a979898e6d1454c0780df0eead705e (patch)
treeae26d9a404fd7913e4567f913189ebb3d52aead8 /src/string.c
parentee8875b1d583c23d521edf4234daff4a83f9ec2f (diff)
parent84e9c4befe071d95ff36baf2faf76a7a6d52bc1e (diff)
downloadmruby-2040347d26a979898e6d1454c0780df0eead705e.tar.gz
mruby-2040347d26a979898e6d1454c0780df0eead705e.zip
Merge pull request #1650 from cremno/remove-str_mod_check
string.c: remove str_mod_check
Diffstat (limited to 'src/string.c')
-rw-r--r--src/string.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/src/string.c b/src/string.c
index e8c37180d..7d0cdaf0d 100644
--- a/src/string.c
+++ b/src/string.c
@@ -107,16 +107,6 @@ mrb_str_resize(mrb_state *mrb, mrb_value str, mrb_int len)
return str;
}
-static inline void
-str_mod_check(mrb_state *mrb, mrb_value str, char *p, mrb_int len)
-{
- struct RString *s = mrb_str_ptr(str);
-
- if (s->ptr != p || s->len != len) {
- mrb_raise(mrb, E_RUNTIME_ERROR, "string modified");
- }
-}
-
#define mrb_obj_alloc_string(mrb) ((struct RString*)mrb_obj_alloc((mrb), MRB_TT_STRING, (mrb)->string_class))
/* char offset to byte offset */