summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
authorXavier Noria <[email protected]>2024-01-09 20:04:20 +0100
committerAaron Patterson <[email protected]>2024-01-12 12:24:48 -0800
commitaad246feba1579cc3c34f8309845692e2f11babd (patch)
tree884c0bc4d8969336a5961fe3688bd1085709ad79 /hash.c
parent774eef692cc9708b22959ef57b8472a375772189 (diff)
s/SafeStringValue/StringValue/
The macro SafeStringValue() became just StringValue() in c5c05460ac2, and it is deprecated nowadays. This patch replaces remaining macro usage. Some occurrences are left in ext/stringio and ext/win32ole, they should be fixed upstream. The macro itself is not deleted, because it may be used in extensions.
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/hash.c b/hash.c
index 2ccd3cd008..6a23f16957 100644
--- a/hash.c
+++ b/hash.c
@@ -4898,7 +4898,7 @@ static inline const char *
env_name(volatile VALUE *s)
{
const char *name;
- SafeStringValue(*s);
+ StringValue(*s);
get_env_ptr(name, *s);
return name;
}
@@ -5375,8 +5375,8 @@ env_aset(VALUE nm, VALUE val)
env_delete(nm);
return Qnil;
}
- SafeStringValue(nm);
- SafeStringValue(val);
+ StringValue(nm);
+ StringValue(val);
/* nm can be modified in `val.to_str`, don't get `name` before
* check for `val` */
get_env_ptr(name, nm);
@@ -6239,7 +6239,7 @@ env_rassoc(VALUE dmy, VALUE obj)
static VALUE
env_key(VALUE dmy, VALUE value)
{
- SafeStringValue(value);
+ StringValue(value);
VALUE str = Qnil;
ENV_LOCK();