This articles was published on 2017-07-09

mruby 1.3.0

Since 16. November 2015 mruby 1.3 was in the making. After 596 days and 907 commits by 38 contributors I can happily announce that we released the latest stable version of mruby on 4. July 2017. mruby is a lightweight implementation of the Ruby programming language. Applications of mruby include embedded programming on micro-controllers, sandboxed Ruby scripting support, standalone binaries (e.g. command-line tools and deployment receipts), container management and more.

Contributors

The following 38 contributors have committed code to this release:

Asmod4n, Bouke van der Bijl, Clayton Smith, Craig Lehmann, Daniel Bovensiepen, Edgar Boda-Majer, Felix Jones, Francis Bogsanyi, Francois Chagnon, Herwin Weststrate, Hiro Asari, Jun Takeda, Kazuho Oku, Kenji Okimoto, Kouhei Sutou, Kouichi Nakanishi, Masahiko Sawada, Miura Hideki, Nobuyoshi Nakada, Ryo Okubo, Shugo Maeda, Sorah Fukumori, Takashi Kokubun, Tomasz DÄ…browski, Tomoyuki Sahara, Uchio KONDO, Yasuhiro Matsumoto, Yuji Yamano, Yukihiro “Matz” Matsumoto, Yutaka HARA, bggd, crimsonwoods, hhc0null, ksss, okkez, palkan, robert and Takeshi Watanabe

Standard Library

With 77 commits we improved the following parts of the standard library:

  • implement Array #dig, #try_convert, #slice!
  • improve Array #[]=
  • implement Enumerable::Lazy #to_enum, #enum_for
  • improve Enumerable #take, #cycle, #first
  • implement Float #~, #&, #|, #^
  • implement Hash #dig, #try_convert
  • improve Hash #[], #dup
  • implement Kernel #frozen, #caller
  • implement Module #name
  • implement Numeric #zero?, #nonzero?
  • implement Object #freeze
  • improve Proc by removing #initialize
  • implement Struct #dig, #freeze
  • implement String #rjust, #try_convert, #each_char (with block), #each_line (custom separator), #upto (re-implemented)

Language

The following language specific changes were done:

  • &. “Safe navigation (lonely)” Operator added
  • ||= “or equals” operator added

API

The API has changed in the following ways:

  • implement inline structure MRB_TT_INLINE
  • implement MRB_BYTECODE_DECODE_OPTION option
  • improve mrb_range_beg_len (compatibility breaking change)
  • promote mrb_load_exec to public API
  • promote mrb_hash_value to public API

Documentation

Features are only useful if users know that they exist and how to use them. For this reason we worked on improving the general documentation situation of mruby, including a description of how mruby is different to standard Ruby:

  • document limitation of mruby
  • improve API documentation of mruby.h
  • improve API documentation for variable.h
  • improve API documentation for Hash
  • improve API documentation for Array

Build System

One of the targets of mruby is to be used on as many platforms as possible. The following improvements of the build system of mruby should help to make mruby easier to be used in different environments:

  • improve Visual Studio 2010, 2012, 2013, 2015 build support
  • deprecate Visual Studio 2010 and 2012
  • refactor Android build target
  • improve usage of C with mruby
  • improve general Android toolchain
  • add support for Android armabi-v7a
  • add support for Android arm64-v8a
  • add support for Android armabi
  • add support for Renesas RX630 hardware
  • add support for Intel Edison hardware
  • add support for OpenWRT toolchain

Security audit and general bug fixing

The majority of the work on this release was to fix bugs. As mentioned earlier, the Shopify bug bounty served as a security audit of the mruby code base. It revealed a massive amount of potential security related issues inside the source. All together 293 commits were contributed to fix security related issues related to this bug bounty. Another 159 commits were provided to fix general bugs.

Commits

Here is complete list of all commits for the mruby 1.3.0 release:

Standard Library

740bf09 add bit operators ~,&,|,^ to Float class (mruby special)

daf8394 add #dig to Array,Hash and Struct

e86bc6b Add String#rjust to mruby-string-ext

621487a add {Array|Hash|String}.try_convert

451985d Implement Module#name. Solves #2132.

88604e3 Hash#[] to call Hash#default

bef63a4 Support to call without block to String#each_char

bd72dba Kernel#local_variables: Make result array unique

022e147 Kernel#respond_to? should return true|false only

d1bc7ca Optimization for String#* for 1-byte strings

57900d8 String#include? does not take integers

92be276 String#{strip,lstrip,rstrip} may cause OOB access

8e0dc6f Correct argument specifications for few methods: – Struct#values_at – Module#define_method – String#chop – String#chop!

92f72c7 make String#[]= to take Ranges as position argument

d83d9cd String#insert should be destructive

0ff3ae1 Range#include?: simplify condition; ref #3255

6f9cb74 Implement Kernel.#caller

10bb7ad Implement Object#freeze

8675975 Implement Enumerable::Lazy#to_enum and enum_for

ac561a5 Add symbol type check for Module#undef_method

efe4f30 Module#define_method supports proc argument

ab5812d Use standard Module(Class)#to_s

fa76bbe mruby-random: add reporting URL since we modified the source

1a8074a Should not define to `Struct` class

c522907 mruby-sprintf: format specifiers o,u,x,b ignore sign( ); ref #3148

176d93d Ranges should not rewrite

8c67e91 mruby-eval: instance_eval should keep target_class; close #3141

0e03a7f mruby-enum-ext: refine minmax

ed5bf72 Fix missing dependency on mruby-print to support ‘puts’

40a9700 support Numeric#zero? and Numeric#nonzero?

a1a157b suppress “can’t convert Float into Integer” in Enumerable#hash

9e2faec Support object does’n have `<` method

338e0ff Copy default_proc by Hash#dup.

aa1f668 instance_eval should pass the receiver as a block parameter; close #3029

1164463 freeze classes/modules; ref #3340

761562b freeze instance variables; ref #3340

31f0ffe Support Enumerable methods

0f774ff Support nil argument as no argument

c28a963 Like a Enumerable#take

2718fed Support svalue

0f90227 Change Lazy class outer

1bf565e Argument more strictly

abc7248 formatting buffer should be bigger for negative dots; ref #3025

f974880 binary format no longer need to preserve org_v

09abdcb negative binary format should not be masked by 10bits; ref #3025

67a6982 Support to return Enumerator for String#gsub,gsub!

673ce23 Suuport custom separator

eba4b1f Check modifiable for String `bang’ methods

a76dc04 Remove default Kernel#method_missing.

76e1035 String#index shouldn’t return nil when “”.index “”

6eb02a8 Use duplicated object for block args

4ee79a8 Support to return enumerator when no block given

b56ad8d \1 sequences as empty strings

fdd9275 Create NoMethodError instance using `mrb_obj_new()`.

e72e50b Hash sub class creates new sub class objects instead of Hash

33f77fe Implement Array#slice!

6dbe227 Set proper class to subclass of Array

d93a5c1 Fix Enumerator#each_with_index with block

5efe77f Modify class variable definition in singleton class; fix #3539

507e00e Modify to get constant of parent module in singleton class; fix #3568

5a445f0 Add alias “append” to Array#push, and “prepend” to Array#unshift.

cff54ab Change return value of Enumerable#each_slice

4975aa4 Change return value of Enumberable#each_cons

5d00e85 Fixed out of bounds access; fix #3572, ref #3553

be5c304 Fix parameters when noname rest

b30eba6 Make `LocalJumpError` a subclass of `ScriptError`.

0411cea Use `MRB_PRId` instead of `d` for mrb_int decimal specifier; ref #3701

e96f254 Use `mrb_str_new()` instead of `malloc()`; ref #3701

473b2bb Should not use `sizeof(buf)` when `buf` is `char*`; #3701

19785f4 Reimplement String#upto

ab85d3c Make `break` in lambdas work as `return` according to CRuby behavior.

98f9c33 String#concat: Try to convert when not string

bdb36b3 Make string embad from shared

ef6e14e Better error message

e05c307 Use `FILL` and `PUSH`

7314423 Fix space flag when Inf/NaN and width==3

da5b7fa Support freeze in `Struct`.

Tools

879e27d mirb: enlarge code buffer size to 4KB

1e34b12 mirb: Don’t exit on Ctrl-C

1c7572b Update mirb.c

068b46d – fix mrbc_filename leak; cxt->filename would not be freed until the state is closed.

401ad45 Add constant export declaration for MRBC output compiled as C

76d44b1 remove execute bit from mrbgems/mruby-bin-debugger files

e1cc814 add next command to mrdb.

52a0380 Add –libmruby-path support to mruby-bin-mruby-config.

Documentation

afee618 Added documentation on function for globals

18d6994 Documented most methods in mruby/hash.h

d20c56c Documented most methods in mruby/array.h

cc5f40b mrb_class_under_defined docs renamed parent and child to outer and inner

f02694e Update documentation of fetch

189ad47 yard docs for string.h

af33394 Undid newline and whitespace on YARD doc

4e267d7 Added YARD docs in new mruby.h

90b7ec8 YARD doc for mrb_str_to_cstr.

46fbd53 Add more limitations: – defined? – alias on global variables – Operator modification – Kernel.binding missing

44d26dd Add more limitations

1887042 add 1/2 description to limitations.md file

3bbc486 Add limitation file

38b9c2d mruby-fiber: add Fiber.yield description; close #3066

7a7fac8 removed ChangeLog that has not been updated for long time; ref #3190

af4567b update copyright notice and license description for mt19937ar.[ch]

0b14389 Remove historical comment; ref #3450 #3448

6c181fa Update README.md

d296120 Update README to mention ruby version management tools

70283a9 Update license year range to 2016

2c77dfa Update Copyright to 2017

3943ab5 Update AUTHORS

f9f19f3 replace _cstr by _lit for litral C strings; ref #3300

22464fe mruby-1.2.0

89eac4f Update codegen.c comments

277391e Set the mruby-1.3.0 release date to `2017-7-4`.

4d3027b Increment the version number to `1.3.0`.

497a0a7 Correct comments in gc.c

4f0900e Fix a typo in gc.c.

27a5e10 Avoid using C style comments (//).

bb0b52a Update comments regarding Exception#to_str

Language, Parser, Compiler and GC

73dd82e parse.y: lparen_arg statement

a06940d parse.y: simplify 90e8ce5

90e8ce5 parse.y: rescue modifiers for OP_ASGN should protect rhs only

752ca51 do not dump_node if parser failed

2e81fee parser_dump() to show symbol number for NODE_SYM

6b84ff4 Print NODE_SCALL (&.) from mrb_parser_dump()

27ceb84 parse.y: use opt_paren_args to simplify yield rule

1c95939 Add “void value expression” check to the parser.

2eefbfe Fix crash in mrb_parser_free() due to freed memory access

451523f Avoid Syntax Error on CRuby v1.8

968ebac Bytecode decoder support, MRB_BYTECODE_DECODE_OPTION

be550f0 codedump.c: OP_POPERR does not have register access.

dc4be19 Add forgotten loop_pop() in NODE_OP_ASGN codegen

669bbc7 codegen_scope should not keep old iseq ptr from irep

3886bec better code generation for `||=`; #3138

185dad3 node_dump() to print NODE_HEREDOC terminator

29d3a40 stack adjustment after NODE_OP_ASGN with NODE_CALL was wrong; fix #3159

cc3f1b7 allow single quoted labels in hashes; ref #3231

6bb0775 Reduce needless Array generation in some String methods

34ac707 OP_ASGN vsp may be negative

9dc8205 Should raise LocalJumpError when no block given

73e5a19 Configure callinfo target_class as CRuby; ref #3429

b23fb45 Integral#step without arg should loop forever as CRuby does.

af21b36 symname_p support `!~`

819c9da peephole optimization for LOADNIL before STRCAT; ref #3110

4979b52 reduce OP_ARRAY in argument splat

803bf01 save/restore arena index around yield; ref #3359

0af170f gc.c: dead_slot is boolean; ref #3339

7b968ca Clear parsing_heredoc at the end of file

1ce471c `||=` with cvars and constants should work with false values; #3138

4fcff34 `||=` reference error can happen with constants as well; #3138

adadbf5 in `peekc_n`, adjust column number after calling `nextc`

c69cba2 Add missing regs update

25e4ec3 cache UTF8 status for utf8_strlen(); ref #980

fed40b4 Extract read_escape_unicode from read_escape

0f08914 Support multiple elements \u syntax

2ef634e do not destroy a page with an active TT_ENV (e.g. an env referred from TT_FIBER)

aec825a stack_extend before eval_under()

9145aed bytes2chars() conversion to fail if target byte offset is not on the character boundary; ref #3067

a4ae22a Failed to realloc irep->syms in certain condition.

2bb47ad Prohibit instantiation of immediate objects

63dbed0 `__FILE__` should not update `p->filename`; fix #3485

22eb41a Fix NODE_DREGX dump; ref #3471

dc56bbe Ignore empty ensure clause.

d219e63 Clear block arg when method_missing takes *args.

4f43db8 Unshare popped TT_ENV objects.

ecee8c5 Avoid tracing shared TT_ENV object.

21a3ae0 add safe-navigation (aka lonely) operator `&.`

3531fe1 GC must scan env from fibers even when it’s not yet copied to heap; fix #3063

00faf3d Fix compilation error with GC_PROFILE.

ec35e54 need to free context when reclaiming fiber object in GC; fix #3109

dce3005 GC Arena docs pass for fixups

f1eb3ae Fix segmentation fault by backtrace and GC

09b1185 mrb_gc_unregister() to remove one registration; close #3160

c2e749f fix issues of mrb_gc_unregister introduced in 09b1185

e22f37a Argument order of __case_eqq was wrong; fix #3567

666787b Adjust exit point in `loop_pop()`; fix #3541

aee1476 Provide better way to check compile errors.

ea250d5 Increment `RITE_BINARY_FORMAT_VER`.

a985847 Store operands to local variables.

d7e09ff Print the file name along with line number on syntax errors; fix #3698

52443c8 Save the register value in a local variable for ease of debugging.

af6041f Ensure size of the stack in OP_CALL.

fc7096f Limit recursion level of `codegen()`; fix #3690

7f417ad Revert “Update NODE_BLOCK check logic in `void_expr_error`.”

31e3068 Update NODE_BLOCK check logic in `void_expr_error`.

0f2f021 Fixed a bug in `void_expr_error`.

90fb4dd Print most recent call last as CPython does.

9f634a6 Mark the current context (not root) in final marking.

f269d1e Distinguish OP_R_NORMAL and OP_R_RETURN.

ff46957 Avoid using `mrb_raise()` in `mrb_vm_exec()`; ref #3660

9bca887 Preserve the current pc before `method_missing()`; fix #3660

d2458e6 Remove class info from backtrace lines.

497b19c Support the case when the backtrace is not an array.

24a24a4 Type check before `print_backtrace()`

3de2da4 Avoid call to_s during backtrace traversal

01f7825 Use fiber marking instead of `mark_context`.

b112046 Revert “Simplify pointer calculation in `envadjust`.”

d54f9f8 Fix embedded document with unterminated terminator

3b0a36d Alias should `push()` extra stack space for blocks.

a1d32af Simplify pointer calculation in `envadjust`.

79e0314 Call envadjust() before updating VM stack.

a0143e1 Make `mrb_codedump_all()` to print type of Proc.

f4119f5 Changed evaluation order of `yield`; ref #3613

f6c70bc `super` may call context switching method like `send`; fix #3611

05fceb5 Call exc_debug_info() in mrb_exc_set(); ref #3610

82ab461 Add “no super” check to OP_ARGARY; fix #3610

c396184 Hash#dup didn’t check if internal khash is initialized; fix #3609

7614939 Mark whole root objects in final_marking_phase(); fix #3603

ab25eae Avoid clearing VM stack every time to gain performance.

0cb5015 Fill omitted arguments by nil for non-strict Proc.

15b55c3 Attach a name to embbeded value of rescue/ensure stack size

Build and platform topics

fd08e0e Added example build script for Android armeabi-v7a NEON hardware FPU

324231a Android toolchain separated target architecture compile flags (ctarget) from shared compile flags (cflags). Added support for custom mfpu and float-abi switches for the armeabi-v7a target.

5395dbf Add new two build config files.

6420951 Update example lines of mrbgems in build_config.rb; ref #3414

aa90ad5 Add default benchmark build config

bfc7b2e deprecate Visual Studio 2010 and 2012

b83bcd1 Removed GCC TODO

3e9fe81 Android GCC support re-added

5fd068e Android task: NDK default search paths now favour ndk-bundle. Added macOS NDK search paths.

18662ff Re-written android.rake task for latest Android NDK clang. Currently loses support for GCC and mips, mips64. Addresses issue #3208

87e5b0f Add appveyor.yml for Visual Studio 2015/2013

51cb729 Create appveyor_config.rb

2aa6b44 Reduce compiler include_paths

a27426a Added example for cross-compiling on Intel Edison

1636ad4 C compiler does not like cast from pointer to enum; ref #3039

67e3cdf Implemented round(double) function within mruby-time gem, for it is missing on VisualStudio compilers where _MSC_ver < 1800

1315667 Separate compilers setup from config setup

d86f5d2 mruby architecture detection

1ba61f0 Remove webhook notification for Travis CI

b2fceae renamed class.rb and error.rb to ensure they are read first; ref #3197

e5fedaf Not only for MINGW but also for Visual C

c9d4d96 surpress warning when MRB_DISABLE_STDIO

ac9b6f2 In mrbgem_spec.rake, added support for @mrblib_dir @objs_dir, so that a gem can have custom source directory names

e5cce38 Suppress a warning

c6a1172 Add pointer cast to pacify warnings.

37d2d57 Use underbar’ed name to get rid of warnings

44de80f fix a compiler warning for uninitialized variable

e3bc81e Fix warning shift-negative-value

6cb7aef Add type cast to pacify warning

f67631a C doesn’t have try-catch

121c6e3 use _setjmp/_longjmp on other BSD flavors

f4bb329 use _setjmp/_longjmp on OS X

cd8284f Fix build error when trace mode

bd2b76e Build fix for 32-bit clang 3.8/3.9 with MRB_INT64

eda6c1d fix build on vs2013-vs2015

fb1c4b3 Fix broken msvc build

30b0100 fix VS2010/2012 build

d0668cf Fix build error in ruby 1.8.

7cc33af fix build on VS2012

a6b1e96 Modify default cflags.

83a3da4 Set default linker ‘flags’ and ‘flags_before_libraries’.

52aba8a Avoid Error when Compiling with -std=c99 flag

fcbaafa Add toolchain support for OpenWRT

39b6a9d define macros only if builtins are n/a

18757c8 Different method of compiling C as C (-x c )

c27dbfe disable define const on VS

065966d common.h are supposed to be included from other header, so call it with quotes; ref #3032

237d26f Support pkg-config in mrbgem.rake

76eb714 Added example for cross-compiling for Renesas RX630

ee7fc56 Put package’s libs flag after %{objs}

6187c21 Wrapped string.c errno with ifndef macro for platforms that use inbuilt errno macro

00e6121 Safeguard against trying to use C exception handling in C code

931cc03 printf precision parameter must be ‘int’ type

cea6a16 Fixed some compiler errors regarding PRId.

f99e100 MiniRake::Task#timestamp should use Time.now only

2d858ca Use C ABI only when MRB_ENABLE_CXX_ABI is set; ref #3470

0bcf9e2 Reorganize C exceptions; ref #3470

1a1f834 Compile C files by C compiler when C files mixed.

da4f8e1 replace “yylval” with “pylval” to make it compile with byacc.

ffdf7be Define jmpbuf_id outside of `extern “C”`; ref #3470

838fa69 Add ‘-Wl,–fix-cortex-a8’ linker option for ‘armeabi-v7a’ architecture.

5d2795c Fixed mips and mips64: GCC Toolchain now points to GCC.

d7a6070 Fixed language standard mode for GCC (cannot use gnu99 with C , c 03 used instead)

d0e42ef Ignore file generated by ctags

de114eb Change AppVeyor’s clone_depth

9057a3f Add macOS support to mrb_ro_data_p

cef523c Avoid duplicated `envadjust()` of env stacks; fix #3637

3e07a2d Silence warnings caused by implicit type casting.

88cd807 Avoid use of `snprintf()` when DISABLE_STDIO is set; fix #3632

b2dc043 Align pool allocator with 8 byte in 64-bit environment.

API

0360a74 Promote load_exec to mruby API as mrb_load_exec (fixes #3248)

91bd3eb Remove needless MRB_API

7a382e8 Remove unnecessary MRB_API from read_irep related functions; ref #3215

f7afe1d change mrb_run related API names; compatibility macros provided

bd462c5 mruby-fiber: fiber_switch() to use nesting VM when it’s called from C API or mrb_funcall(); close #3056

36fabe1 new API function mrb_string_value_len()

4d38cad Add MRB_API to mrb_range_beg_len(); ref #3411

5c651d6 add MRB_API to mrb_float_read(); ref #3270

afbe211 mrb_str_strlen() should be MRB_API; ref #3216

e02a88e make mrb_hash_values() a public API function

28cf7a5 Change return type of mrb_range_beg_len() from `int` to `mrb_int`.

5e1d923 Changed the behavior of mrb_range_beg_len(); close #3411

9781f7f Add “not reached” mark in mrb_ary_concat()

df35076 Restore callinfo offset in mrb_yield_with_class()

b491f4b set `MRB_64BIT` if the sizeof(size_t) is 8

3fdfd8c Safeguard against using MRB_INT64 with MRB_WORD_BOXING in 32-bit mode

f5a86ca Add pointer casting from mrb_malloc(); ref #3267

8d6aa06 Added mrb_class_under_defined

c45ed46 macro mrb_bool() may evaluate arg multiple times; ref #3228

ae5b5ce vm.c: mrb_hash_set() may reallocate VM stack; close #3133

5e514c9 cache mrb_regexp_p(); ref #980

f3cce24 replace mrb_toplevel_run() by mrb_top_run()

7c82bfa mruby-sprintf to use mrb_int formatting macros; ref #3076

cd131d1 define `MRB_PRI?` that map to `PRI?NN` depending on the size of `mrb_int`

d69b5c3 Add case statement of MRB_TT_SCLASS in mrb_obj_is_kind_of()

2a234a9 mrb_str_len_to_inum(): string may not be NUL terminated; ref #3043

ca417da mrb_str_len_to_inum(): inspect string in error message

d3a56a6 mrb_cstr_to_inum(): should ignore trailing white spaces even when badcheck set

dbb8cf6 mrb_str_to_inum(): should raise error when string contains null byte

9f2fca6 mrb_str_to_inum(): no need to call mrb_string_value_cstr() here; ref 05411ee

05411ee mrb_string_value_cstr() should not raise error for frozen strings

5ec051f Avoid inline local variable declarations; fix #3554

d27a3d4 String#initialize to make a string empty; ref #3574

bb1bfaa Add helper functions to use gdb reverse-next.

Test

24048cd Tests for UTF-8 String#ljust and String#rjust

3f83ec6 Add test for recently fixed bugs

7685783 Add regression test for Enumerable#cycle

6170504 test/assert.rb should not use puts

46995c3 add quoted symbol tests; ref #3231

d467022 Add testing for regression

1751d8f Add new test for optimize VM

bf21063 Add regression test

8a15ab0 add test for public_methods(false)

481aa31 Update doc, write about add_test_dependency

dd072b5 remove wrong ISO section from safe navigation test; ref 4c1ce0f6

817b884 add #dig tests

4c1ce0f add safe-navigation operator tests

cb1a80e Add String#rjust test to mruby-string-ext

2a661ac Add tests which passes all zero string to Kernel#Integer

1d7d706 __t_printstr__ may not be available for tests

0ebac02 Skip backtrace related tests when backtrace isn’t available

95edcc8 Test against latest xcode

1ef2faf Remove unnecessary dependencies for assert_rb codegen and test_rbireps

e7a3018 Remove mrbtest_irep from mrbtest

f085baa Pass when assert returns a false value

9a76a0b Move mrb_assert() position.

3bedd22 Add assertion to make sure new capacity does not overflow.

b21b024 asserts checking validity of pointer and TT added for mrb_obj_value

c385782 mrb_assert definition moved to the beggining of mruby.h

ba1cd56 Fixed an unit test to work on Cygwin.

563036e Restore `test/t/codegen.rb`

e0fbf25 Remove tests which can not be compiled on CRuby.

Security Audit

c7262be Fix segfault in Array#sample

9bf1c0e Fix segfault when Fixnum#chr doesn’t return a string

73bb30c Copy over INSTANCE_TT when duping class

73e4f06 Fix nested empty heredoc causing segfault

55842c5 resolve conflict; ref #3279

82731d9 Remove constant when a struct is redefined.

743c1e7 stop warnings in the test; ref #3280

b60d6c4 Don’t allow array parameter in Struct.new

79e3980 resolve conflict; ref #3281

4523aae Fix segfault when defining class inside instance_exec on primitive

75b31d7 Fix segfault on method call with exactly 127 arguments

30f12ba resolve conflict; ref #3283

22f5504 Fix segfault on remove_method with invalid argument

1253982 Fix codegen issue causing misaligned register

cc2786c resolve conflict; ref #3285

71641bb Fix segfault caused by empty condition in ternary

0b4017f resolve conflict; ref #3286

1ec5994 Fix calling .arity on Proc with undefined `initialize`

76a1bdf Get String length after args in String#chomp!

83005d8 Read length after args in String#setbyte

964427f Fix unsafe peephole optimization

a384bcc Fix instances where return value of mrb_method_search_vm is unchecked

144006a update NoMethodError tests; ref #3291

36fc1f1 Added Exception check in mrb_exc_set(); close #3292

630733f check ttype before object allocation; fix #3294

b7f9a58 Fix null pointer dereference in mrb_time_initialize

277e81a removed failing test for Time#initialize; ref #3295

3774311 should not refer Struct class by name; fix #3296

5771c97 add a test for #3296

523c267 Interpret argument in ‘f ()’ as nil instead of nothing

9c61e1c Use mrb_ptr instead of mrb_cptr in Kernel#to_s

7d07466 Fix stack move segfaulting in OP_ARYCAT

fe362c1 Fix segfault when using result of rest assignment

6be5160 Fix 36fc1f14 not checking in the right location

d56a19c Don’t generate code for NODE_NEGATE if the result isn’t used

c2bbfa5 NODE_NEGATE cdr may not be code-node; fix #3348 ref #3324

f7a891f Mark all the built-in classes during GC sweep

c8da3c4 Fix segfault when undef is called with exactly 127 arguments

1264219 Fix segfault in gen_values with NOVAL and more than 127 args

b633aa9 Use size_t to calculate bytes needed for array.

acdddb4 Prevent array size calculation overflows.

ab4ab7c Fix compile error by #3309

2bc3a5f Fix more integer overflows.

79a621d Check before retrieving struct RRange pointer; fix #3320

1ff4b3f Fix segfault in mrb_proc_copy.

3a7c369 Make sure str->capa is under MRB_INT_MAX; fix #3342

1ed4de5 str_buf_cat(): better size check added; ref #3342

73ad739 Check type before calling mrb_range_ptr.

868d2e5 Fix crash when exponent is -2147483648

2edf15b Prohibit mixture of posarg and nextarg; ref #3347

4325707 Check if width is zero or negative before fill; fix #3347 (also ported to MRI)

c2bbfa5 NODE_NEGATE cdr may not be code-node; fix #3348 ref #3324

270ea41 method_missing() may have CALL_MAXARGS-1 arguments; fix #3351

5c1c002 Fix segv when primitive value

9d84f0d ary_expand_capa(): size calculation by size_t; fix #3353

cfdd1e3 ary_expand_capa(): refine conditions to avoid infinite loop; ref #3353

caba1a1 Check array max size

5e3077c One less argument for raisef(); fix #3355

3cba13c Proc shouldn’t have `initialize` method

a68b568 Should call initialize method if defined

eeca6ec Rewrite String#prepend with Ruby

c626b82 Check overflow string length

0de65a8 Do nothing when empty string

c4491e4 Validate tm values before timegm(); close #3368

2e0c2b5 Add mrb_hash_modify() to Hash#{delete,clear}; ref #3370

36f5b44 Add new method Kernel#frozen?; ref #3370

ddcb30d Check intern object returned by mrb_check_string_type

f53f73f Should not deallocate shared string referring static; fix #3373

e1ff710 String#replace should check replacing string; fix #3374

3ce8260 Fix memory leak; ref #3378

f0f095b Fix a double free problem in codegen.c; fix #3378

392d7fb Add ary_modify() checks; close #3379

b3ce364 Outer class may be same as the class; fix #3382

47cc5d6 Singleton classes do not have outer class set; fix #3505

8a15abd Avoid trampoline code if mrb_f_send is called from funcall; fix #3383

7523cdf Exception#initialize to take arbitrary number of args; ref #3384

44edc51 Raises Exception if raising exception class is redefined

db1bd07 Use temporary variable to avoid potential crash; fix #3387

8e0f231 Mark `mrb->backtrace.exc` as GC root; fix #3388

06b2e6a Check if ci->target_class is NULL before dereferencing

2f299cf Simplify expression; ref #3490

ff262f2 Update ci->mid according to surrounding scope; fix #3490

2c0f8f1 Remove problematic optimization.

c48aef0 Stack position may be bigger than stack bottom; fix #3401

bc4c90d Use mrb_int for argc.

51d7a69 Clear (o).w first for MRB_WORD_BOXING; ref #3396

ac88f85 Copy mrb_float values from pool when MRB_WORD_BOXING; ref #3396

38acb9e Kernel#initialize should not break existing mt; fix #3397

a357124 Add proper stack size calculation; fix #3398

797ff62 Fix incorrect parsing of block parameters.

65c9baa Rewrite mrb_ary_splice

fdec607 Remove unnecessary inline declaration; ref #3409

49fd759 Use mrb_write_barrier() instead of mrb_field_write_barrier_value()

ffb5e5a The ensure clause should keep its ci after its execution; fix #3406

708088c Should not make empty strings shared; fix #3407

28b7b9e Skip non string values in backtraces; ref #3408

324887d Backtrace list must be an array of strings; fix #3408

72bff29 Use size_t to avoid integer overflow in mrb_ary_splice(); fix #3413

bf4e79c `argv` may be modified when `mrb_funcall()` is called; fix #3419

719f700 Extend mruby stack when keep is bigger than room; fix #3421

30aa521 Do not use mrb_funcall() if Hash#default is not overridden; ref #3421

8efa7b0 Preallocate SystemStackError; ref #3421

1e5b5b1 Prohibit too deep `mrb_funcall()` recursion; ref #3421

ecb6ac8 Fixed codegen error of redo in rescue; fix #3422

4ab7029 Revert 642ab8e; ref #3422

f3d4ff1 Fixed a bug in ci address shifting; fix #3423

8f52b88 No need to make env unshared in the finalization; fix #3425

6e0ba00 Jump address should fit in 16 bits range; fix #3426

a8ccda5 Fetch arguments earlier to avoid a crash.

1f2d786 Avoid direct return from ecall(); fix #3441

af4d74f Add MRB_TT_PROC check to OP_SUPER as well; fix #3432

642ab8e `ecall()` should preserve stack address referenced from ci[1].

c2ddcd4 Should handle `break` from funcall(); fix #3434

76135e7 Check if m->env is NULL before dereferencing it; fix #3436

b277c58 Mark classes referenced from saved backtrace.

4b32e65 Check if irep is NULL before print_backtrace()

c789acb Save/restore arena index in the loop.

dcf6a41 Use `snprintf()` to stringify fixnum numbers; fix #3492

3703aed Use `snprintf()` to stringify fixnum numbers; ref #3492

ff03a9a Avoid integer overflow in sprintf(); fix #3439

f198530 Fixed too much value_copy() when block is not given; fix #3440

8b089c0 Keep space for safe navigation operator; fix #3475

27ec243 Fix possible stack overflow for `method_missing`; fix #3478

eca35df `ci` may be moved during `mrb_convert_type()`; ref #3474

3390020 The method_missing removal condition in a76dc04a was wrong.

b64f087 Protect stack region before calling mrb_convert_type(); fix #3504

981105b String#ljust and String#rjust reimplementation (fix #3445)

b563bcb Check if OP_RETURN cross C function boundary; fix #3462

736be0e Always keep block argument space in stack; fix #3469

50bbdbb Fixed ecall() invoked too early; fix #3464

9e93d5d Stack may be reallocated in mrb_run(); fix #3465

3b40a2f Limit ecall() recursion levels; fix #3466

7db0786 Fix integer overflow; fix #3473

bdac7df Check if the value is fixnum before mrb_funcall(); fix #3476

74dbee8 Add check before calling str_substr(); ref #3476

405f5a2 Add type check by mrb_get_args(); ref #3476

1ab7e7e Fixed a bug in register size calculation; fix #3479

000c68d OP_RETRUN to take B as matching exception; ref #3487

26169f9 Enhance OP_RESCUE to take B operand fas matching exception; ref #3487

92f5bec Update VM to support new OP_RESCUE behavior; ref #3487

916b8ed Generate new OP_RESCUE; fix #3487

4763312 Terminate loop if generated string longer than the last; ref #3489

c6e5659 Use string#upto() if available; fix #3489

e8f09f9 Raise special Exception when exception class is redefined; fix #3493

f30ec2d fixup! Check return value from snprintf(); ref #3498

e392231 Check return value from snprintf(); ref #3498

94395e8 The width printf specifier may be negative; fix #3498

191ee25 Need to copy argv since it may be reallocated; fix #3500

877f43b OP_BLKPUSH is invalid outside of methods; fix #3501

b2916f1 Avoid mrb_check_string_type() in raising exception; fix #3506

75c374c Update stack only when callinfo is popped; fix #3521

e6b5c75 Avoid possible infinite recursion in mrb_print_error(); ref #3517

8d1468e Remove cname duplication from exc_inspect().

6ea26aa Save/restore GC arena index to avoid arena overflow error.

ef105b5 Use MRB_PRId instead of “%d”; fix #3515

527dcd5 `super class error` formats the superclass by `inspect`; rerf #3515

0957492 Should not check/call `to_str` for immediate objects; ref #3515

d01118d OP_RESCUE refactored; ref #3519

4cf38eb Fixed OP_RESCUE code generation bug; fix #3519

2cbbeba Check call depth when mrb_yield_class() is called; ref #3521

051e40c Use MRB_PRId for NODE_NTH_REF; ref #3530

9eb0c11 Cast to mrb_int to silence a warning; fix #3530

a6e25f7 Renumber hash keys during dup since there may be duplicates.

db3573e Should raise FloatDomainError

397f1fc Fix infinity loop

b1c5c3b Fix lost lineno

39ca4ef Avoid crash if hv.n is greater than kh_size(h); fix #3565

195af52 Expand stack for method_missing; fix #3528

8d9d7c9 Improve Time.new() performance using division; fix #3561

1e87dfd The stack may be reallocated in the func call; fix #3560

dcbfe71 NODE_ASGN arguments may be 127 (CALL_MAXARGS) accidentally; fix #3559

56322cd Pacify signed warning; ref #3565

071164b Should not shrink VM stack; fix #3551

93d8029 Extend VM stack just in case; ref #3551

a49c9f8 Update callinfo->target_class in mrb_exec_irep(); fix #3543

8193c0b Check before generating special operators (e.g. OP_ADD); fix #3557

a14a930 Remove unnecessary indirection; ref #3557

f5632f2 Restrict recursion levels in method_missing(); fix #3556

d35fcf1 NODE_SPLAT to pass VAL/NOVAL; fix #3532

246db71 Add `struct REnv` to union `RVALUE`; ref #3534

0a1f15e Insert ` mrb_field_write_barrier()` for GC; fix #3534

b8461c8 Protect ensure clause lambdas from GC; fix #3491

ab63ee6 Fixed out-of-bounds access of `ensure[]`; ref #3491

6dabb33 Adjust VM stack window size; fix #3547

dc4fba2 Correctly handle large negative usec value.

1a3b323 Copy argv from VM stack to avoid use-after-free; fix #3722

0de7eec Fixed disclosure of local variables by `eval`; ref #3710

08c385f Mark the GC arena in `final_marking_phase`.

819ccd3 Mark the root context in `final_marking_phase`.

8daabe7 Mark global variables in `final_marking_phase`; fix #3704

d4d99dd Allow `break` from a block called by `mrb_yield`; close #3359

6a66ce1 Need to unshare env from top callinfo; fix #3685

ebd6636 Call write barriers for stack-modified fibers; fix #3699

47bd44f Prevent Fiber#initialize to be called twice; fix #3705

b298e24 Protect the last exception object from GC in `ecall`; fix #3702

357e478 Mark the exception object in the final marking phase; ref #3702

988e2ce Ensure size of the stack before handling exceptions; fix #3693

b979226 Clear stack in OP_CALL; fix #3694

7830b84 Fixed uninitialized local variable bug; ref #3692

edb5b36 Avoid out-of-bound access of VM stack in OP_SENDB; fix #3692

b9f771d Handles exceptions from code generation phase; fix #3695

788cea2 Revert “Simplify rescue stack management; ref #3683

c9a4f8a Prohibit changing generational mode during GC disabled; fix #3689

935649b Check if a block is a lambda before marking it orphan; ref #3640

c041206 Add checks for `break from proc-closure`; fix #3640

a8bf374 Fixed a bug that make a loop in singleton_class clone; fix #3687

b59d244 Add more precise void expression checks; ref #3686

079f310 Adjust ridx if `mrb_yield` terminated by `break`; fix #3686

51e0e69 Avoid invoking GC when disabled or iterating; fix #3681

87cc034 Call `stack_clear()` after `stack_extend()`; fix #3682

eb5a606 Simplify rescue stack management; ref #3683

7ff90b5 Simplify ensure stack management; fix #3683

72b635f Hide OP_EXEC lambda body from `ObjectSpace#each_object`; fix #3680

a893877 Check for super using OP_ARGARY; fix #3678

b0f2bc3 Clear VM stack in OP_EXEC; ref #3678

eb69eeb Simplify code since OP_EXEC never takes CFUNC Proc; #3678

ff7df93 Restore MRB_API function `mrb_exc_backtrace(mrb, exc)`; ref 9644ad5

9644ad5 Simplify backtrace mechanism; fix #3633 #3634 #3644

2837de9 Prevent splicing big recursive arrrays; ref #3679

b4a4e3c Simplify the logic in `mrb_realloc`; ref #3679

7dbbd77 Revert 4566c80; fix #3679

877f9d0 Avoid infinite loop on negative exponent; fix #3677

acd3ac6 Reduce the size of VM stack clear window; ref #3676

2599c19 Clear VM stack for top level; fix #3676

ef11584 Check env context before jump from OP_RETURN; fix #3673

4b15d5d Initialize String before Exception; fix #3672

650cfb9 Exceptions in fibers must be re-raised via `#resume`; fix #3675

cbd4aae Mark the proc object representing top-level as an internal object; #3621

abed375 Mark proc objects representing methods as internal objects; fix #3621

02670ff Protect the returning value in OP_RETURN; fix #3669

57ffa1c Avoid unsharing env when context (mrb->c) differs; ref #3668

e3438f4 Invoke ensure clauses on Fiber termination; fix #3666

83fc915 Add new range check macro FIXABLE_FLOAT(); ref #3652

535f13f fixup! Let Fixnum#{ceil,floor,round,truncate} to return itself; #3652

c80696f Let Fixnum#{ceil,floor,round,truncate} to return itself; #3652

06c4933 Try our own `ipow()` if both base and exp are fixnums; fix #3652

7e47316 Fixed off-by-one error in `fiber_switch()`; ref #3641

f75f506 Revert 01f7825; fix #3650

ac442bc Raise an exception when transfer arguments are too many; fix #3641

de48d95 Avoid marking possibly freed stack; #3550 #3612

c53747d Revert “Use env preserved in Proc structure in ecall(); fix #3612

517cd51 Invoke ensure clauses before switching context from fibers; fix #3662

ed16535 Clear top level env in `mrb_top_run()`; fix #3643

f88cb88 Avoid unsharing stack if env refers top-level; ref #3643

e093112 Check env stack length before `OP_SETUPVAR`; ref #3643

e969229 Check backtrace info may not be set (esp. NoMemError); fix #3663

3ef97e3 Under MRB_INT64, width may be bigger than INT_MAX; fix #3665

bf30b8e Change return back to break in the default case.

a1ea2a6 Use index in `each_object`.

b08dced Stop invoking GC before `each_object` to avoid test failure; #3616

aa8e490 Prevent GC during `each_object`; fix #3616

03cdb8e Should terminate nested iterations in each_object; ref #3359

058da1f Revert “Disable GC during `gc_each_objects()`; fix #3616

e26e118 Use env preserved in Proc structure in ecall(); fix #3612

5513fce Keep reference to mrb_context from env; fix #3619

ad3b61f Revert e8dca6b03; fix #3550

15fba69 Revert ae4217e81; fix #3619

94bcdca VM stack may be reallocated in `mrb_convert_type()`; fix #3622

262fbaf `mrb_int` may overflow in bit-shifting; fix #3620

3567b26 Bit-shifting zero should be zero; ref #3620

d2cad9a Disable GC during `gc_each_objects()`; fix #3616

62dae09 Allow `mrb_objspace_each_objects()` to break iteration; ref #3359

edd9fc6 Do not raise an exception for living closure; ref #3359

6a0b68f Use trampoline technique for `instance_exec`; ref #3359

77c2aa7 Need to raise “break from proc-closure” error; fix #3359 fix #3495

283d145 Fixed a bug caused by last minute change; fix #3610

de96994 Check if sc->mt is initialized before copying it.

ae4217e Fixed a wrong condition; fix #3550

e8dca6b Revert 6dd1a57; fix #3612; ref #3550

8e2279d Fix an off-by-one causing a buffer overflow in mirb.

045e78c Proc#call needs to reserve at least 2 registers; fix #3606

17377af Struct may not be initialized in #to_h; fix #3607

aec121f Update NODE_XSTR, NODE_DSXTR tests; ref #3605

3123549 Fixed a bug in NODE_XSTR code generation; fix #3605

4e84bdb Let ‘mrb_vm_run()` to restore the calling fiber; ref #3537

0fb05eb Should not unshare env stack repeatedly; fix #3601

2a4db1a `method_missing` might have updated stack beyond boundary; fix #3599

326e043 Exceptions may be raised in yyparse(); fix #3600

918e7bb Refactor check before `mrb_class_ptr()`; ref #3602

a25404c The attached object may not be a class; fix #3602

6dd1a57 Shared TT_ENV may need to be marked; fix #3550

fff4a4e OP_LAMBDA generation should honor VAL/NOVAL; fix #3580

db47ae5 Fixed a bug in `mrb_convert_to_integer()`; fix #3581

03c8493 Fiber#yield should check C function boundary; fix #3582

9094415 An object attached to a singleton class may not be a class; fix #3587

0048dd1 Protect arguments from GC; fix #3597

a55b237 Callinfo may be changed in `ecall()`; fix #3589

47f1815 Avoid updating regs[] from function calls; ref #3588

d9fb8b6 Fixed a bug in OP_SUPER block conversion; fix #3590

bd7bf26 Should specify instance type of Structs; fix #3591

2daebfb Fixed a bug when method_missing take 126 args; fix #3592

60d20e1 Should restore to the root fiber for each interaction; fix #3537

74712c7 Need to insert write barriers in struct updates; fix #3547

Error Handling

7453a5d use mrb_int_mul_overflow()

6369374 add mrb_int_mul_overflow(); close #3149

9a21aa2 preserve original string for error message

3d9aa46 Add NULL checks for Time data retrieval

b49bd70 Should raise RuntimeError when object frozen

59d9f31 Skip when backtrace doesn’t get

8d61f21 Add proper given argument number in the wrong-number-argument error.

dffb4d8 Add type check for cls before allocation

23c73ff Time#initialize_copy: Check if source time is initialized.

227daa8 Relax ‘void value expression’ check that was too strict

7276e84 use type-generic checked arithmetic builtins

d77c72d Revert “Merge pull request #3126 from jbreeden/backtrace_irep_null_check”

e02ff85 Null check for irep & initialize loc.lineno

3c73c31 Hash: check flags before accessing ifnone; ref #980

5134734 Shouldn’t call `each` method if size is 0

798c69d Avoid casting from int to unsigned char for C ; ref #3267

fb77765 hash value may be overflown from Integer

3623a83 Protect exceptions within main() function

0c28c7d change backtrace sep from const char* to char

a561bdb Support backtrace after method calls

85bd997 avoid comparison between signed and unsigned

9a962ed Raise an exception in time_update_datetime().

2cca9d3 avoid comparison between signed and unsigned integer; ref #3312

bfbc6b9 local_variables() should not touch unshared env

f5f48d9 protect NoMethodError from calling to_hash in replace

885d929 Improve capacity enhancing conditions

342b1de str_buf_cat(): should allocate at least RSTRING_EMBED_LEN_MAX 1.

9cef265 should not try to set classpath for frozen classes; ref #3340

339c6ae Add explicit cast from float to mrb_int.

3fc9bf3 Update local variable only after the value is checked.

7a74a61 Callback should yield with pattern every time

6db38c3 Need not to call mrb_obj_as_string() is sep is nil.

9a59cd7 Silence `mrbmemcpy` and `mrbmemset` warnings.

af0bef6 Silence rubocop warnings.

Refactor

b165708 Move #instance_exec to Kernel module

517e931 Move #__id__ to BasicObject; ref #3417

612d636 Move #instance_eval to BasicObject; ref #3417

3dbda91 Move #__send__ to BasicObject; ref #3417

8b4bd31 Move #== and #!= to BasicObject; ref #3417

3f9450e Move BasicObject#method_missing to Kernel#method_missing; ref #3417

1422e57 move mrb_str_dup() to mrb_class_path; ref #2470

01dddaf rename mruby-module-ext to mruby-class-ext; ref #2470

ff3e4b9 Move Module#include and #prepend to class.c; ref #3197

51cc35d Remove needless assignment

611e99e remove unnecessary array/each

62b06ab [cppcheck] mrb_str_rindex() remove unnecessary len update by chars2bytes()

af4dd3d [cppcheck] remove duplicated break

725b3ca move KHASH_DECLARE(ht..) to mruby/hash.h; close #3073

825ced1 remove duplicated local variable declaration

d3f59db Remove redundant conditions of Array#each in ruby extension

996417c integer range check was moved to mrb_flo_to_fixnum(); ref #3025

b130f43 remove skip that shouldn’t be necessary anymore.

fe0884f Removed ununnecessary escape character ‘\’ for MRUBY_XXX in libmruby.flags.mak

73cc087 remove debug code; ref #3344

2827655 Removed unnecessary const macro – const keyword is already a dependency

fe86cf4 Removed the errno declaration from string.c

c029c6c codegen: avoid unnecessary OP_MOVE after CASE

8112295 Removed fix_shift_get_width()

a701047 remove unnecessary “.!”; ref #3261

2e8ed95 Removed mruby-inline-struct gem from default.gembox; ref #3251

6511bfd Removed trailing spaces

8f4a929 String#replace should update s->flags for MRB_STR_NO_UTF.

ac9d04f String#ljust and String#rjust reimplemented with optimized Ruby

682237b Reimplements Range#first

126d554 Reimplement Enumerable#cycle

efebbbb Implement Float shift methods in C

78a395d Refactoring: Use array_copy instead of for loop

0429692 Use mrb_funcall_argv() instead of mrb_funcall()

f388b6d use size_t instead of int

30b6648 Small refactoring: should use RSTR_CAPA

a630c4f use MRB_PRId instead of %d for mrb_int

22390aa Use mrb_float instead of double

339005e intptr_t should be used instead of uint32_t to hold a pointer.

8438792 renamed “inline” to “istruct” to represent inline struct; ref #3251

e3c8092 Renamed class_under_defined to class_defined_under

36c0847 Use non-underscore’ed names

e279854 One space indentation.

8807690 Refactor Array#each

bc1259d add explicit casts

dd24f9f Avoid calling hook methods if they are not overridden.

4fdec33 simpler t_print

81acbd2 cosmetic change for OP_EQ

d4ee409 Use stack directly

6c1b6ef Use memchr for performance

f0205e1 rename include blocker

8cba708 int64_value(): use FIXABLE()

5c405de include changed from by quotes (“”) to by brackets (<>); close #3032

2005bf9 Should use mrb_int for any object

38a3b89 Small cosmetic change (“* ” -> “*”).

9b176a1 Avoid using <mruby/throw.h> in mruby.c

952207d small cosmetic change; ref #3570

fbf4089 Remove spaces around parens

77331d1 Unify `else` clause style

7f98392 Reduce object allocation

12f6496 Revert “Adjust VM stack window size; fix #3547

e9cdc88 Refactor `sprintf()` code.

466a18b Remove redundant use of `Object#to_s` in interpolation.

3554a41 Remove unnecessary initialization of a local variable.

7944d9a Make `mrb_load_exec` a static function.

464d3fc Use `alias enum_for to_enum` instead of `alias :enum_for :to_enum`.

057be5f use `unless` instead of `if not`.

667e788 Use `mrb_int` instead of `int` as argument to `mrb_hash_new_capa`.

b0f918d Use `mrb_int` instead of `int`.

aa8121c Use `mrb_int` instead of `size_t` for array capacity and length.

9e6a3f6 Use `MRB_THROW` instead of `mrb_exc_raise`.

4d9ca27 Use malloc instead of dynamic allocation

54b45f6 Use RData instead of String to represent backtrace.

3c31278 Fix indentation in mrb_init_numeric()

9e40586 Add cast to `mrb_int` in `mrb_fixnum()` when MRB_WORD_BOXING.

8cba9a9 Adjust to the optimum type

92dcfba Add explicit cast from double to long.

cd4e9a0 Refactor “%f” % Inf/NaN

a4dfaaf Small cosmetic changes.

95229ee Assign to local variable first; cosmetic change.

d4205c9 Use while statement instead of for statement

Bug

097da23 Avoid executing OP_STOP in eval(); fix #3429

e4fa59f Fixed aspec for Kernel#caller

90f262f Revert “Optimization for String#* for 1-byte strings”

d0ecf86 Fixed mixture of signed/unsigned integers

46e4e34 Fix interpolation escaping in String.inspect

48e0bbb Make `eval` to use trampoline technique; fix #3415

c830698 Dots is not needed for base 10 negative numbers; fix #3400

af4f6e8 Fix a typo.

8a9a241 Fix memory error on str_buf_cat

fead715 tLABEL should not come after conditional ternary; fix #3344

647ad29 Fixed wrong condition in new_sym() that breaks symbol data.

92c843d rename prefix RBASIC_ to MRB_; ref #3340

43512cc Reorganize heredoc rules; fix #3273

a0fbc46 Import locale insensitive strtod() from Ruby1.8; fix #3270

f6d1999 Needed to apply block from safe-navigation operators; fix #3310

bd9bc77 Fix assertion argument orders

8461a31 Fixed too much void_expr_error(); fix #3307

246a9a8 ary_concat: support self concatenation; fix #3302

626648d Fixed NaN boxing when MRB_INT16 is set

be52233 Fix typo in istruct.h

22f7325 redo should work well in for statement; fix #3275

72ed7ee Fixed Range.size to use proper floating point tolerance

a8b8abb Fixed float tolerance in tests when MRB_USE_FLOAT is set

0c924b9 fixed a bug in self modifying Array#[]=; fix #3274

cb5c9d3 always call Hash#default if no key found; fix #3272

c2a60eb Fix for Windows-specific mruby C issues

44c3859 Fix for compiling mruby as C on Visual Studio toolchain

1af9e36 Fixes for compiling mruby as C

52b40cb Fixed extern “C” to use MRB_BEGIN/END_DECL in re.h

be73905 accept floats as bit operator operands; fix #3260

aaa86a1 Fix typo in test

8cdaf1e Fixed NaN boxing for 64-bit configrations on platforms that use full 48-bit usermode pointers

4289e0c Fix for sprintf test exceeding bounds with MRB_INT16

a2fbd80 Fix Range#size results

4ef591c Fix condition of Range#include?

c043dc6 Typo fix: poped => popped

4cca8ba inline structures data type for mruby (MRB_TT_INLINE) (fix #3237)

1685eff Fixed off-by-one error in String#[]= with Ranges

1f554ff Fixed rindex calling into mrb_equal bug

242b219 Fixed memory disclosure in String#lines

739dad6 Fixed a memory problem in Array#to_h

4f6cce0 class/module statement should re-open; fix #3225

45aadd7 HEREDOC could fail with NUL terminated lines; fix#3244

3f002b6 fixed a bug when number of LHS and RHS differs; fix #3239

872517d class variables in higher order have a priority; fix #3235

1142cf2 fixed a bug with [] in RHS of multiple assignments; fix #3236

6c299aa fixed wrong stack adjustment for ensure clauses; fix #3175

0b8d8dd associate REnv to the executing block; fix #3214

13d0832 allow quoted labels in hashes; fix #3231

9a12627 should not unshare() reclaimed env objects; fix #3230

6fd0e60 Move to_proc conversion from OP_ENTER to OP_SENDB; fix #3227

b1fa180 Fix unexpected behavior with break

cb29c9b Fix return value type of bytecode_decoder

5f37d8b Fix a couple typos in limitations.md

04ae296 Fixed regex order falling early in arch cases, causing x86_64 and arm-v7a to use wrong target.

d265c03 Fix SEGV when splat object

e66b35c Fix SEGV when unshared env

22dc84f Fixed spell errors in test/t/lang.rb; ref #3199

861b0ee Fix String#ord failure which return a negative value

f6a2f67 Correct method name

bdd7e2b parse.y: fix chained assignments

ada264a instance_eval env should remake Fix #3191

4170923 Fixed crash error when #initialize is redefined for Struct; fix #3177

d4d807b relax string length limitation to 64KB; fix 2725

8764bd2 fix public_methods(false)

6b0299f fixed remaining bugs in OP_ASGN stack adjustment; close #3159

bf63cff fix MRUBY_VERSION value

309791b raise the error at runtime; fix #3152

1863f32 fix syntax highlighting

d97a37e fix possible memory leak in mruby-time gem

e1e888e fix too much optimization for `||=`

d098d82 fix duplicated eval in op_asgn

2b0baec fixed silly class variable/constant confusion; #3138

a02acf2 rescue NameError from class variable access like `@@foo ||= 42`; fix #3138

a138ae3 Fix doesn’t work bintest on :visualcpp toolchain

41d6ba2 fix dump_prefix() with wrong type argument; fix #3128

d2a8f7e Fix Travis CI

b8479b6 too many register push for else-less condtions; fix #3117

cf5ca03 mruby-struct: copied Struct length is not initialized; fix #3114

d8fc09c push value for NULL AST when value is required; fix #3110

da96c33 syntax error in interpolated symbol; fixed #3108

668cc1b Fix segfault when `eval(“__FILE__”)` is executed

299cb5a Fix formatting again…

5976185 Fix bug in mruby-test gem.

37344ec fixed typos in limitations.md

e7eb40f Fix formatting

983948c Small format fix

9442cb9 Fix a typo

c77123d Fix SEGV by stack extension in mrb_get_args()

8a74e68 mruby-random: fixed wrong fixnum conversion

793a629 Small grammar fix

1d84b32 Fix SEGV on re-raising NoMemoryError

787685a Fix all zero string case

ad492eb Fix class variable reference in module

fb2e0b7 fixed a problem with upvar access from instance_eval; ref #3072

146a9ee Fix segfault on mrb_exc_backtrace.

258cb20 mruby-eval: fixed receiver value in eval context; close #3072

1eeeecb Fix indent

887a56b fix bug that doesn’t stop program when execute next command.

a08439a fixed next command’s comment.

3f228c1 Fix “ambiguous first argument” warning

f54a98f mrb_str_len_to_inum(): fixed a bug with MRB_INT_MIN conversion; fix #3048

d18c55f mrb_str_len_to_inum(): fixed a bug with underscores in digits; fix #3049

19c744e mrb_str_len_to_inum(): fixed a bug with separating _ in the digits; ref #3043

26a25e1 mrb_str_len_to_inum: should not raise “string contains null byte” error on “0x”; fix #3043

ad333cd mrb_str_len_to_inum: converting may not be terminated by NUL; fix #3044

0701236 mrb_str_to_inum(): should treat null byte in strings properly; fix #3040

c299651 should ignore block to next, break, etc. fix #3039

058ffcb Fix MRB_DISABLE_STDIO typo.

40f237e Fix typo on MRB_DISABLE_STDIO.

1a9b607 binary sprintf should not be restricted by mrb_int size; fix #3025

470fce5 Fix check for VisualStudio Version in mruby-math gem

ef95dcd Bugfix nagative-number lshift() bit overflow

a4d5588 Bugfix lshift() bit overflow; close #3023

d6cbe1b The original code crashed when mrb->backtrace.n grew to 16. It looks like the logic to reallocate the backtrace was flawed, based on the wrong variable (loc_raw->i, which, as I have verified, decreases from 16 to 0 instead of increasing)

b0886d5 Zero length heredoc still crashed; ref Shopify/mruby-internal81

f2b18a6 Check maximum number of formal arguments.

8dde647 add temporary workaround for irep memory corruption

b3236b2 mruby-random: fixed typos

8f0c1c7 mruby-sprintf:fix double negative signs in printf; fix #3148

5e3c329 Adjust callinfo env and target_class; ref #3429

1e57fef Do not funcall() Exception#set_backtrace from runtime.

9fc62d2 pre-allocate arena overflow error

fe0e455 Initialize callinfo->acc; ref #3243

07167b8 Initialize potentially uninitialized variable tsec.

8b77979 Initialize potentially uninitialized variable z

a5c2e95 Should clear method name

d196e4d void_expr_error(): n may be NULL.

c52bbe1 Fixed a bug in dregex option generation; fix #3471

cd0ac59 Newlines in strings should be counted; fix #3477

fb3243e `return` (and `break`) should handle splat correctly; fix #3472

fa502b4 Need to setup singleton_class chain; fix #3509

00427d4 Fixed access of uninitialized C local variable; fix #3525

fca17b4 Avoid trampoline when #eval is called from mrb_funcall(); fix #3522

f8b31a0 `instance_eval` method does not introduce C function boundary; fix #3508

d8c4fe7 Fix out-of-bound access

4b3e6cf Avoid infinity loop when empty string pattern

63c0044 Fix result if pattern is empty

31bc2b0 Initialize `flags` for each loop.

15945e1 Revert “Make `mrb_load_exec` a static function.”

432a813 Fix arena overflow error

b32ad13 The out-of-memory error should not be an instance of RuntimeError.

4566c80 Free given pointer if `realloc()` fails; fix #3658

8e390cc Fixed rounding functions (round,ceil,floor,truncate) in MRB_INT64.

34dd258 Unwind callinfo (mrb->c->ci) when a fiber termitates with error.

5e1a6a2 Make `gen_assignment()` to support `NODE_SCALL`; ref #3658

30df7c8 Fix segmentation fault ref: #3648

5d67d9b Fixed a possible memory leak.

3ce42a0 Add missing `arg_i ` to fix bug of `s!` in mrb_get_args.

33d09e4 Fix typo in usage message.

4fca570 Find Class/Module in nested singleton class; fix #3598

5c114c9 Clear unused stack region that may refer freed objects; fix #3596

491d68b Skip stack marking at all if c->stack is NULL.

c063641 Clear local (but non-argument) variables in OP_ENTER.

fd0f79c Get constant of parent class even if child class is defined in signleton class; fix #3575

e5b61d3 Fixed possible SEGV in `Kernel#block_given?`; ref #3593

5e79bc9 Make String#replace to check equality before modifying flags.

a7b0ab3 Save block argument position in e->cioff; fix #3593

7f37c2f Use stderr for debug prints in DEBUG(); fix #3584