Commit Graph

18 Commits

Author SHA1 Message Date
Yukihiro "Matz" Matsumoto 079244c36a src/class.c: add new function mrb_vm_find_method
The function skips `cp` dereference, and improve performance of method
calls slightly.
2023-01-23 00:17:32 +09:00
Yukihiro "Matz" Matsumoto 3a7e138c05 mruby/internal.h: add mrb_env_new to the internal function header 2023-01-18 10:37:48 +09:00
Yukihiro "Matz" Matsumoto 55eea005c8 mruby/internal.h: add codedump functions to the internal function header
ref #5906
2023-01-18 10:37:48 +09:00
Yukihiro "Matz" Matsumoto bf642becc2 internal.h: aggregate prototypes to internal.h.
- mrb_f_send()
- mrb_ci_nregs()
2022-11-02 14:24:42 +09:00
Yukihiro "Matz" Matsumoto 4107cc95a2 internal.c: move some functions to <mruby/internal.h>.
Ref #5776
2022-08-15 18:13:59 +09:00
Yukihiro "Matz" Matsumoto 37dc1be74b internal.c: move mrb_method_missing prototype to <mruby/internal.h>.
Ref #5776
2022-08-15 17:25:08 +09:00
Yukihiro "Matz" Matsumoto a7c3d59971 kernel.c (mrb_obj_hash): generate hash value for big-integers. 2022-08-06 06:43:41 +09:00
Yukihiro "Matz" Matsumoto 6d683785f9 etc.c: use mrb_byte_hash instead of simple hash function. 2022-08-06 06:43:41 +09:00
Yukihiro "Matz" Matsumoto c0a636c007 mruby-os-memsize/memsize.c: add up digit spaces for big-integers. 2022-07-21 20:56:32 +09:00
Yukihiro "Matz" Matsumoto bae11ef689 complex.c (mrb_complex_copy): allow copying of complex numbers. 2022-07-11 11:25:31 +09:00
Yukihiro "Matz" Matsumoto 67f47c9b42 rational.c (mrb_rational_copy): allow copying of rational numbers. 2022-07-11 11:19:22 +09:00
Yukihiro "Matz" Matsumoto 3ebb55b75f bigint.c (mrb_bint_copy): allow dup operation for bigints. 2022-07-11 11:02:27 +09:00
Yukihiro "Matz" Matsumoto 7de03cbb68 numeric.c: add mrb_noreturn qualifier to error functions.
- mrb_int_zerodiv()
- mrb_int_overflow()
2022-07-09 15:12:37 +09:00
Yukihiro "Matz" Matsumoto e1980d7596 numeric.c (mrb_div_int): separate the function in two.
- mrb_div_int() does integer division in Ruby way (mdiv)
  returns mrb_int
- mrb_div_int_value() division with zero div and overflow checks.
  returns mrb_value
2022-07-09 14:38:18 +09:00
Yukihiro "Matz" Matsumoto cd6e94c09f mruby/internal.h: move functions from internal.h; #5725
To compile `iij/mruby-require` gem.
2022-06-23 07:53:29 +09:00
Yukihiro "Matz" Matsumoto b38a766427 numeric.c (flo_to_i): use bigint if the value is bigger than mrb_int. 2022-04-18 12:31:15 +09:00
Yukihiro "Matz" Matsumoto dcaf4083d5 src/bigint.c: implement multi-precision integer.
To enable multi-precision integer support, you need to link
`mruby-bigint` mrbgem. The gem itself is empty but it turns on
the "bigint" support.
2022-04-09 17:16:10 +09:00
Yukihiro "Matz" Matsumoto b99c389ec3 internal.h: aggregate internal functions.
Internal functions can only be called from within the library.
Functions listed in `mruby/internal.h` can be called from:

* core (src/*.c)
* gems (mrbgems/**/*.c)

But not from the application linked with `libmruby`.
2022-04-02 18:25:13 +09:00