From d8720eb7de9cd9d874b621f214c27022e17cc941 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Wed, 8 Apr 2020 16:06:30 +0900 Subject: Suppress -Wshorten-64-to-32 warnings --- ext/digest/digest.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ext/digest/digest.c') diff --git a/ext/digest/digest.c b/ext/digest/digest.c index a59f880ac7..cde0dfa005 100644 --- a/ext/digest/digest.c +++ b/ext/digest/digest.c @@ -406,7 +406,7 @@ rb_digest_instance_digest_length(VALUE self) /* never blindly assume that #digest() returns a string */ StringValue(digest); - return INT2NUM(RSTRING_LEN(digest)); + return LONG2NUM(RSTRING_LEN(digest)); } /* @@ -725,7 +725,7 @@ rb_digest_base_digest_length(VALUE self) algo = get_digest_obj_metadata(self); - return INT2NUM(algo->digest_len); + return SIZET2NUM(algo->digest_len); } /* @@ -740,7 +740,7 @@ rb_digest_base_block_length(VALUE self) algo = get_digest_obj_metadata(self); - return INT2NUM(algo->block_len); + return SIZET2NUM(algo->block_len); } void -- cgit v1.2.3