summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/digest/md5/md5init.c4
-rw-r--r--ext/digest/rmd160/rmd160init.c4
-rw-r--r--ext/digest/sha1/sha1init.c4
-rw-r--r--ext/digest/sha2/sha2init.c2
4 files changed, 7 insertions, 7 deletions
diff --git a/ext/digest/md5/md5init.c b/ext/digest/md5/md5init.c
index 3cf0c1a..433fbbd 100644
--- a/ext/digest/md5/md5init.c
+++ b/ext/digest/md5/md5init.c
@@ -40,6 +40,6 @@ Init_md5(void)
#undef RUBY_UNTYPED_DATA_WARNING
#define RUBY_UNTYPED_DATA_WARNING 0
- rb_ivar_set(cDigest_MD5, rb_intern("metadata"),
- Data_Wrap_Struct(0, 0, 0, (void *)&md5));
+ rb_iv_set(cDigest_MD5, "metadata",
+ Data_Wrap_Struct(0, 0, 0, (void *)&md5));
}
diff --git a/ext/digest/rmd160/rmd160init.c b/ext/digest/rmd160/rmd160init.c
index 572638b..7c0c1a0 100644
--- a/ext/digest/rmd160/rmd160init.c
+++ b/ext/digest/rmd160/rmd160init.c
@@ -40,6 +40,6 @@ Init_rmd160(void)
#undef RUBY_UNTYPED_DATA_WARNING
#define RUBY_UNTYPED_DATA_WARNING 0
- rb_ivar_set(cDigest_RMD160, rb_intern("metadata"),
- Data_Wrap_Struct(0, 0, 0, (void *)&rmd160));
+ rb_iv_set(cDigest_RMD160, "metadata",
+ Data_Wrap_Struct(0, 0, 0, (void *)&rmd160));
}
diff --git a/ext/digest/sha1/sha1init.c b/ext/digest/sha1/sha1init.c
index 56ae0fa..bb4af1c 100644
--- a/ext/digest/sha1/sha1init.c
+++ b/ext/digest/sha1/sha1init.c
@@ -40,6 +40,6 @@ Init_sha1(void)
#undef RUBY_UNTYPED_DATA_WARNING
#define RUBY_UNTYPED_DATA_WARNING 0
- rb_ivar_set(cDigest_SHA1, rb_intern("metadata"),
- Data_Wrap_Struct(0, 0, 0, (void *)&sha1));
+ rb_iv_set(cDigest_SHA1, "metadata",
+ Data_Wrap_Struct(0, 0, 0, (void *)&sha1));
}
diff --git a/ext/digest/sha2/sha2init.c b/ext/digest/sha2/sha2init.c
index 8a5faee..7b39bda 100644
--- a/ext/digest/sha2/sha2init.c
+++ b/ext/digest/sha2/sha2init.c
@@ -41,7 +41,7 @@ Init_sha2(void)
rb_require("digest");
- id_metadata = rb_intern("metadata");
+ id_metadata = rb_intern_const("metadata");
mDigest = rb_path2class("Digest");
cDigest_Base = rb_path2class("Digest::Base");