diff options
author | Nobuyoshi Nakada <[email protected]> | 2024-10-26 21:06:29 +0900 |
---|---|---|
committer | git <[email protected]> | 2024-10-26 12:55:45 +0000 |
commit | 393c5df00855829aaa7ce2f9964be673f5373ae0 (patch) | |
tree | 198fc3da11cbd698da446886e5e5230837596984 /ext/stringio/stringio.c | |
parent | 519f559113c138b08125ae399ea83c369c5ad624 (diff) |
[ruby/stringio] Remove `SafeStringValue`
In Ruby 2.7 and later, it is the same as `StringValue`.
https://github.com/ruby/stringio/commit/561ea67ea8
Diffstat (limited to 'ext/stringio/stringio.c')
-rw-r--r-- | ext/stringio/stringio.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/stringio/stringio.c b/ext/stringio/stringio.c index 07e970f295..863f9ab201 100644 --- a/ext/stringio/stringio.c +++ b/ext/stringio/stringio.c @@ -957,7 +957,7 @@ strio_ungetc(VALUE self, VALUE c) return strio_unget_bytes(ptr, buf, len); } else { - SafeStringValue(c); + StringValue(c); enc = rb_enc_get(ptr->string); enc2 = rb_enc_get(c); if (enc != enc2 && enc != rb_ascii8bit_encoding()) { @@ -992,7 +992,7 @@ strio_ungetbyte(VALUE self, VALUE c) } else { long cl; - SafeStringValue(c); + StringValue(c); cl = RSTRING_LEN(c); if (cl > 0) { strio_unget_bytes(ptr, RSTRING_PTR(c), cl); |