mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
dc5566e560
`int_fit_limb_p()` checks if `mrb_int` fits in `mp_limb`. Previous logic did not work well with negative integers.
Multi-precision Integer extension for mruby
This extension uses fgmp, which is a public domain implementation of a subset of the GNU gmp library by Mark Henderson markh@wimsey.bc.ca. But it's heavily modified to fit with mruby. You can get the original source code from https://github.com/deischi/fgmp.git. You can read the original README for fgmp in README-fgmp.md.
If you want to create your own Multi-precision Integer GEM, see examples/mrbgems/mruby-YOUR-bigint/TODO-HINT.md.