summaryrefslogtreecommitdiffhomepage
path: root/src
AgeCommit message (Collapse)Author
2017-08-25fix fmt_fp.c(329) : warning C4244: 'return' : conversion from 'ptrdiff_t' to ↵Tomasz Dąbrowski
'int', possible loss of data
2017-08-25fix fmt_fp.c(251) : warning C4244: '=' : conversion from '__int64' to 'int', ↵Tomasz Dąbrowski
possible loss of data
2017-08-25fix fmt_fp.c(224) : warning C4244: '=' : conversion from 'ptrdiff_t' to ↵Tomasz Dąbrowski
'int', possible loss of data
2017-08-25fix fmt_fp.c(220) : warning C4244: '=' : conversion from '__int64' to 'int', ↵Tomasz Dąbrowski
possible loss of data
2017-08-25fix fmt_fp.c(206) : warning C4244: 'initializing' : conversion from ↵Tomasz Dąbrowski
'ptrdiff_t' to 'int', possible loss of data
2017-08-25fix fmt_fp.c(178) : warning C4244: 'return' : conversion from 'ptrdiff_t' to ↵Tomasz Dąbrowski
'int', possible loss of data
2017-08-25fix fmt_fp.c(123) : warning C4244: 'return' : conversion from 'ptrdiff_t' to ↵Tomasz Dąbrowski
'int', possible loss of data
2017-08-23Asserted bidx < ci->nregs for OP_SEND and OP_SUPERChristopher Aue
2017-08-22Added method cache.Yukihiro "Matz" Matsumoto
To enable method cache, define `MRB_METHOD_CACHE` or `MRB_METHOD_CACHE_SIZE`. The cache size must be power of 2. The default cache size is 128. The measurement: I measured simple benchmarks found in benchmark/ directory. With method cache enabled, we gained 6-8% performance improvement, with 97-99% cache hit rate.
2017-08-22Remove possible path that leaves a local variable uninitialized.Yukihiro "Matz" Matsumoto
2017-08-22`mrb_obj_respond_to` to use `mrb_method_search_vm`.Yukihiro "Matz" Matsumoto
2017-08-22`strlen` returns `size_t`; need to cast before assigning to `int`.Yukihiro "Matz" Matsumoto
2017-08-22(Try to) fix mixture of `int` and `size_t` in UTF-8 conversion.Yukihiro "Matz" Matsumoto
This only effects VC.
2017-08-19Reduce signed/unsigned warnings in dump.cYukihiro "Matz" Matsumoto
2017-08-19Reduce signed/unsigned warnings in fmt_fp.cYukihiro "Matz" Matsumoto
2017-08-19Use `ptrdiff_t` instead of `int`.Yukihiro "Matz" Matsumoto
2017-08-19Remove mixed signed/unsigned comparison in debug.c.Yukihiro "Matz" Matsumoto
2017-08-19Type check before traversing `irep->outer`; fix #3782Yukihiro "Matz" Matsumoto
2017-08-19Call `mrb_full_gc` before `gc_each_objects`; ref #3782Yukihiro "Matz" Matsumoto
Otherwise dead object may be seen from `#each_object`.
2017-08-19Zero width `unshift` should not touch memory; ref #3780Yukihiro "Matz" Matsumoto
2017-08-19Unshift pointer move size was wrong (not `len` but `alen`); fix #3780Yukihiro "Matz" Matsumoto
2017-08-18`capacify' for `mrb_str_new_capa` should not be `0`.Yukihiro "Matz" Matsumoto
2017-08-18`mrb_str_cat`: `capa` should not be zero to avoid infinite loops.Yukihiro "Matz" Matsumoto
2017-08-18`mrb_str_cat`: `capa` should be bigger than `total`.Yukihiro "Matz" Matsumoto
2017-08-18`ARY_CAPA` handles capacity for embedded arrays by itself.Yukihiro "Matz" Matsumoto
2017-08-18Reduce signed/unsigned comparison warnings; ref #3785Yukihiro "Matz" Matsumoto
2017-08-18Separate `mrb_str_buf_new` and `mrb_str_new_capa`.Yukihiro "Matz" Matsumoto
`mrb_str_buf_new` is an old function that ensures capacity size of `MRB_STR_BUF_MIN_SIZE` minimum. Usually one need to use `mrb_str_new_capa` instead.
2017-08-18Remove code duplication in `mrb_str_concat`.Yukihiro "Matz" Matsumoto
2017-08-18Merge `str_buf_cat` and `mrb_str_cat`.Yukihiro "Matz" Matsumoto
2017-08-18Merge pull request #3786 from christopheraue/3784_fixYukihiro "Matz" Matsumoto
Reset ci in OP_SUPER after potential realloc
2017-08-18Merge pull request #3785 from miura1729/originalYukihiro "Matz" Matsumoto
Improve Array structure
2017-08-18Improve Array structureMiura Hideki
2017-08-18Reset ci in OP_SUPER after potential reallocChristopher Aue
2017-08-12Reintroduced not storing converted proc directly in the stackChristopher Aue
2017-08-12Removed unneeded ci->nregs checks in OP_SEND and OP_SUPERChristopher Aue
Because of #3504 `ci->nregs = bidx+1` was introduced in b64f08784cc50861dec80c26fce715982c02c9e9. This led to the follow up error #3551 whose fix introduced the `if (bidx >= ci->nregs)` check in 071164b7999d0932fd60fb3c580a6c374ab1cf4f and the `stack_extend(mrb, ci->nregs)` in 93d802987e722444d0520a8d3f28002841c4f825. Then, the code causing #3504 reappeared again in #3590. The fix for it moved the code dealing with the block in OP_SUPER from below the `cipush` to above the `cipush` in d9fb8b69b0621e8cd2c7c43fd8511a83718d7e45. The `if (bidx >= ci->nregs) { ... }` from then on works with the original callinfo and not the pushed one. `ci->nregs` needed to be modified for the pushed one because it is initialized to 0. But for the original ci it is propertly set and a check is not needed.
2017-08-12Extended stack always based on ci->nregsChristopher Aue
2017-08-12Refactored variable usage in OP_SEND and OP_SUPERChristopher Aue
2017-08-12Reduce integer type mismatch warnings in VC.Yukihiro "Matz" Matsumoto
2017-08-11Remove some empty lines; ref #3778Yukihiro "Matz" Matsumoto
2017-08-11Refactored OP_SEND and OP_SUPER and calculate argc right at the topChristopher Aue
2017-08-11Remove an unused argument from `each_backtrace_func`.Yukihiro "Matz" Matsumoto
2017-08-11Defer `mid` update after `unshift`; ref #3776Yukihiro "Matz" Matsumoto
2017-08-11Merge branch 'super_method_missing_fix' of ↵Yukihiro "Matz" Matsumoto
https://github.com/christopheraue/mruby into christopheraue-super_method_missing_fix
2017-08-11Silence integer type conversion warnings.Yukihiro "Matz" Matsumoto
2017-08-11Remove unnecessary inline function `ary_elt`.Yukihiro "Matz" Matsumoto
And the function does not conform the naming convention anyway.
2017-08-11Avoid possible data loss by using `ptrdiff_t`.Yukihiro "Matz" Matsumoto
2017-08-11Should not call `to_str` in `mrb_vformat`; fix #3773Yukihiro "Matz" Matsumoto
2017-08-10Fixed calling missing method through super with 126 argsChristopher Aue
2017-08-10Remove redundant `flo_hash` function.Yukihiro "Matz" Matsumoto
`flo_hash` implemented `15.2.8.3.18` but `Kernel#hash` (15.3.1.3.15) now works for numbers.
2017-08-10Use standard hash functions in `mrb_hash_ht_hash_func`.Yukihiro "Matz" Matsumoto