diff options
| author | Carson McDonald <[email protected]> | 2013-07-06 08:54:18 -0400 |
|---|---|---|
| committer | Carson McDonald <[email protected]> | 2013-07-06 08:54:18 -0400 |
| commit | 9a5e78ae6771c272352d6b59bef264ccac2150ec (patch) | |
| tree | d82c85e504453c8d24e8ee9341c8125ac71058e1 /src/numeric.c | |
| parent | 1d27d4e03f1957e78c10a088ccf0f16268baaa91 (diff) | |
| download | mruby-9a5e78ae6771c272352d6b59bef264ccac2150ec.tar.gz mruby-9a5e78ae6771c272352d6b59bef264ccac2150ec.zip | |
Change width to size_t to fix warning
Diffstat (limited to 'src/numeric.c')
| -rw-r--r-- | src/numeric.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/numeric.c b/src/numeric.c index 6cd82d8b6..e1543c089 100644 --- a/src/numeric.c +++ b/src/numeric.c @@ -998,7 +998,7 @@ fix_xor(mrb_state *mrb, mrb_value x) #define NUMERIC_SHIFT_WIDTH_MAX (sizeof(mrb_int)*CHAR_BIT-1) static mrb_value -lshift(mrb_state *mrb, mrb_int val, int width) +lshift(mrb_state *mrb, mrb_int val, size_t width) { if (width > NUMERIC_SHIFT_WIDTH_MAX) { mrb_raisef(mrb, E_RANGE_ERROR, "width(%S) > (%S:sizeof(mrb_int)*CHAR_BIT-1)", @@ -1010,7 +1010,7 @@ lshift(mrb_state *mrb, mrb_int val, int width) } static mrb_value -rshift(mrb_int val, int width) +rshift(mrb_int val, size_t width) { if (width >= NUMERIC_SHIFT_WIDTH_MAX) { if (val < 0) { |
