summaryrefslogtreecommitdiff
path: root/ext/digest/sha2/sha2init.c
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-08-21 16:41:06 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-08-22 00:19:56 +0900
commita9638511009bb8847dfb037d05bdbbdd685066e7 (patch)
tree3bce36e74b60efde6f302d94d4d73788004dbebb /ext/digest/sha2/sha2init.c
parent74c6662af5d9748baff7c32e8f0baf7996dd898e (diff)
Hoisted out rb_id_metadata
Diffstat (limited to 'ext/digest/sha2/sha2init.c')
-rw-r--r--ext/digest/sha2/sha2init.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/ext/digest/sha2/sha2init.c b/ext/digest/sha2/sha2init.c
index 99450bb..7d21178 100644
--- a/ext/digest/sha2/sha2init.c
+++ b/ext/digest/sha2/sha2init.c
@@ -35,15 +35,13 @@ void
Init_sha2(void)
{
VALUE mDigest, cDigest_Base;
- ID id_metadata;
+ ID id_metadata = rb_id_metadata();
#define DECLARE_ALGO_CLASS(bitlen) \
VALUE cDigest_SHA##bitlen;
FOREACH_BITLEN(DECLARE_ALGO_CLASS)
- id_metadata = rb_intern_const("metadata");
-
mDigest = rb_digest_namespace();
cDigest_Base = rb_path2class("Digest::Base");