summaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)Author
2021-01-26Clarify that contributors agree with MIT license in `CONTRIBUTING.md`.Yukihiro "Matz" Matsumoto
2021-01-26Update `doc/mruby3.md`.Yukihiro "Matz" Matsumoto
2021-01-26Add `doc/symbols.md`. [ci skip]Yukihiro "Matz" Matsumoto
To describe how to use symbols, especially preallocated symbols from C.
2021-01-26Change `mruby-config` to print usage on invalid arguments.Yukihiro "Matz" Matsumoto
Or no argument at all.
2021-01-26Fix the wrong directory `host-bin` to `host/bin`.Yukihiro "Matz" Matsumoto
Where `mruby-config` command should be generated.
2021-01-26Use `MRB_SYM()` for error class retrieval; ref #5277Yukihiro "Matz" Matsumoto
Note that `MRB_SYM()` is only available when `mruby/presym.h` is included. Use `mrb_intern_lit()` otherwise.
2021-01-26Revert "Minimize the changes in #5277"Yukihiro "Matz" Matsumoto
This reverts commit dc51d89ac22acc60b9bfeed87115863565b74085.
2021-01-25Silence 'loss of data' warnings in `symbol.c`.Yukihiro "Matz" Matsumoto
2021-01-25Merge pull request #5297 from hasumikin/fix-typo-in-rite-binary-headerYukihiro "Matz" Matsumoto
Fix TYPO and checking minor version in RITE BINARY HEADER
2021-01-25fix comparison of minor versionHASUMI Hitoshi
2021-01-25fix TYPO in RITE BINARY HEADERHASUMI Hitoshi
2021-01-25Silence 'loss of data' warnings.Yukihiro "Matz" Matsumoto
2021-01-25Fix a bug for the case `frexp()` return `Infinity`.Yukihiro "Matz" Matsumoto
2021-01-25Should use a limit for 32 bit platform; ref 05a8cc44Yukihiro "Matz" Matsumoto
2021-01-25Add description for `mruby-config` in `compile.md`. [ci skip]Yukihiro "Matz" Matsumoto
For easier compiling and linking of the application embedding `mruby`
2021-01-24Define `RAT_INT_LIMIT` for 32 bit platforms.Yukihiro "Matz" Matsumoto
2021-01-24Prohibit `r` suffix after scientific notation (e.g. `1e10`).Yukihiro "Matz" Matsumoto
As CRuby does.
2021-01-24Detect integer overflow in `rational_new_f()`.Yukihiro "Matz" Matsumoto
2021-01-23Remove test debug lines in fallback `presym.inc`Yukihiro "Matz" Matsumoto
ref dc51d89ac22
2021-01-23Fixed typo; ref #5296Yukihiro "Matz" Matsumoto
2021-01-23Merge pull request #5296 from yevgenko/patch-1Yukihiro "Matz" Matsumoto
Fix typo
2021-01-23Fix typoYevhen Viktorov
2021-01-22Minimize the changes in #5277Yukihiro "Matz" Matsumoto
Instead of including `mruby/presym.h` everywhere, we provided the fallback `mruby/presym.inc` under `include/mruby` directory, and specify `-I<build-dir>/include` before `-I<top-dir>/include` in `presym.rake`. So even when someone drops `-I<build-dir>/include` in compiler options, it just compiles without failure.
2021-01-21Reduce size of `mrb_callinfo` by rearranging members.Yukihiro "Matz" Matsumoto
From 48 bytes to 40 bytes on 64 bit platforms (unchanged on 32 bit).
2021-01-21Merge branch 'shuujii-avoid-including-presym.inc-in-existing-header-files'Yukihiro "Matz" Matsumoto
2021-01-21Merge branch 'avoid-including-presym.inc-in-existing-header-files' of ↵Yukihiro "Matz" Matsumoto
https://github.com/shuujii/mruby into shuujii-avoid-including-presym.inc-in-existing-header-files
2021-01-21Fix a bug that `:_1` to cause syntax error; fix #5295Yukihiro "Matz" Matsumoto
2021-01-21Better error messages with yacc tokens.Yukihiro "Matz" Matsumoto
2021-01-21Silence gcc warning from `strncpy()`.Yukihiro "Matz" Matsumoto
2021-01-20Remove CRC16 from dumped mruby binary.Yukihiro "Matz" Matsumoto
`calc_crc_16_ccitt()` consumes a lot of clock cycles in programs like `mrbtest` which loads a lot of dumped binary. Error detection for flaky channels should be done in the higher level. Note: `mruby/c` should be updated to support this change.
2021-01-19Compile `mruby-bin-debugger` with `ci/gcc-clang.rb`.Yukihiro "Matz" Matsumoto
2021-01-18Merge pull request #5294 from ↵Yukihiro "Matz" Matsumoto
shuujii/fix-that-Hash-may-not-contain-any-empty-buckets Fix that Hash may not contain any empty buckets
2021-01-18Fix that Hash may not contain any empty bucketsKOBAYASHI Shuji
The Hash implementation assumed that there were always empty buckets, but sometimes there were only active or deleted buckets (no empty buckets). Therefore, fix it so that this situation does not occur. ### Example ```ruby # example.rb class A attr_reader :v def initialize(v) @v = v end def ==(o) @v == o.v end def hash; @v end def to_s; "#{self.class}[#{@v}]" end alias eql? == alias inspect to_s end keys = (0..31).map{A.new(_1)} h = {} (0..16).each{h[keys[_1]] = _1} (17..31).each do k = keys[_1] h[k] = _1 h.delete(k) end p h.keys ``` #### Before this patch: ```console $ bin/mruby example.rb [A[0], A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8], A[9], A[10], A[11], A[12], A[13], A[14], A[15], A[16], A[30], A[31]] ``` #### After this patch: ```console $ bin/mruby example.rb [A[0], A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8], A[9], A[10], A[11], A[12], A[13], A[14], A[15], A[16]] ```
2021-01-18Merge pull request #5293 from dearblue/fix-5272.2Yukihiro "Matz" Matsumoto
Fix build error for mruby-bin-debugger
2021-01-18Fix build error for mruby-bin-debuggerdearblue
This is a missing change in #5272. This issue was reported by @shuujii. https://github.com/mruby/mruby/pull/5272#issuecomment-761819737
2021-01-17Add tests for `Integer#quo` and `Float#quo`; #5268Yukihiro "Matz" Matsumoto
2021-01-17Fix `int_quo` to do float division; fix #5268Yukihiro "Matz" Matsumoto
2021-01-17Define `Rational#quo`; fix #5268Yukihiro "Matz" Matsumoto
2021-01-17Make `mrb_to_flo()` to convert objects, not integer, not float; #5268Yukihiro "Matz" Matsumoto
Thinking `Ratinal` and `Complex` in mind.
2021-01-16Merge pull request #5292 from dearblue/objspace-memsizeYukihiro "Matz" Matsumoto
Fix NULL pointer dereference with mruby-os-memsize and mruby-method
2021-01-16Fix NULL pointer dereference with mruby-os-memsize and mruby-methoddearblue
If it gets an insubstantial method object with `obj.method`, it will raise a `SIGSEGV` with `ObjectSpace.memsize_of(method)`.
2021-01-16Merge pull request #5291 from dearblue/fix-5272Yukihiro "Matz" Matsumoto
Fixed stack position of return value; ref #5272
2021-01-16Fixed stack position of return value; ref #5272dearblue
When I `#call` the "proc" object created by the `mrb_proc_new_cfunc()` function from Ruby space, the return value did not go into the correct stack position. This can destroy the calling variable. This issue is now caused by #5272. sorry.
2021-01-15Avoid syntax error regarding colons in the expression; fix #5290Yukihiro "Matz" Matsumoto
Reported and inspired by @hasumikin; based on CRuby's `parse.y`.
2021-01-14Merge pull request #5273 from dearblue/fiberYukihiro "Matz" Matsumoto
Capture the return value of `Fiber.yield` via C; ref #5261
2021-01-13Rational denominator should not be zero.Yukihiro "Matz" Matsumoto
2021-01-12Capture the return value of `Fiber.yield` via C; ref #5261dearblue
2021-01-12Merge pull request #5289 from dearblue/sockaddr_unYukihiro "Matz" Matsumoto
Initialize all area of `struct sockaddr_un`
2021-01-12Merge branch 'dearblue-reorganize-ci'Yukihiro "Matz" Matsumoto
2021-01-12Initialize all area of `struct sockaddr_un`dearblue
Members of `struct sockaddr_un` are requesting the definitions of `sun_family` and `sun_path`. https://pubs.opengroup.org/onlinepubs/009696699/basedefs/sys/un.h.html But the other members are optional and environment dependent. In fact, other members are defined in the BSD series. from NetBSD-9.1 <https://github.com/NetBSD/src/blob/da504f75982b244b2288bc9970bbc203bd77a9c1/sys/sys/un.h#L49-L53> ```c struct sockaddr_un { unsigned char sun_len; /* sockaddr len excluding NUL */ sa_family_t sun_family; /* AF_UNIX */ char sun_path[104]; /* path name (gag) */ }; ```