summaryrefslogtreecommitdiff
path: root/ext/bigdecimal
diff options
context:
space:
mode:
authorKenta Murata <mrkn@mrkn.jp>2021-01-14 09:26:15 +0900
committerKenta Murata <mrkn@mrkn.jp>2021-01-14 10:21:10 +0900
commit4d13f3e9da6298a1f8154def2e341ecb7c5fe116 (patch)
treeab9f686963ef85d2c397d995adc1468cbc7b09e8 /ext/bigdecimal
parentb4ade73974f7023bff9059737a8ff73fe1c09f40 (diff)
[ruby/bigdecimal] Explicitly cast size_t to int
https://github.com/ruby/bigdecimal/commit/b1f1ed26c9
Diffstat (limited to 'ext/bigdecimal')
-rw-r--r--ext/bigdecimal/bigdecimal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/bigdecimal/bigdecimal.c b/ext/bigdecimal/bigdecimal.c
index e560c19..66be424 100644
--- a/ext/bigdecimal/bigdecimal.c
+++ b/ext/bigdecimal/bigdecimal.c
@@ -2830,7 +2830,7 @@ rb_float_convert_to_BigDecimal(VALUE val, size_t digs, int raise_exception)
int decpt, negative_p;
char *e;
const int mode = digs == 0 ? 0 : 2;
- char *p = BigDecimal_dtoa(d, mode, digs, &decpt, &negative_p, &e);
+ char *p = BigDecimal_dtoa(d, mode, (int)digs, &decpt, &negative_p, &e);
int len10 = (int)(e - p);
if (len10 >= (int)sizeof(buf))
len10 = (int)sizeof(buf) - 1;