40 Commits

Author SHA1 Message Date
Yukihiro "Matz" Matsumoto 05f377dee4 Use __send__ instead of send. 2018-09-01 11:02:59 +09:00
Yukihiro "Matz" Matsumoto 8c9e712784 Keyword argument implemented. 2018-07-30 22:58:01 +09:00
Yukihiro "Matz" Matsumoto 891839b976 New bytecode implementation of mruby VM. 2018-07-30 22:57:54 +09:00
Yukihiro "Matz" Matsumoto 8f2c62407c Add MRB_METHOD_TABLE_INLINE option.
Now the method tables (in classes/modules and caches) keeps C function
pointers without wrapping in `struct RProc` objects. For the sake of
portability, `mrb_method_t` is represented by the struct and union, but
if the most significant bit of the pointer is not used by the platform,
`mrb_method_t` should be packed in `uintptr_t` to reduce memory usage.

`MRB_METHOD_TABLE_INLINE` is turned on by default for linux.
2017-11-20 18:33:41 +09:00
Christopher Aue 35deaae776 Tested LocalJumpErrors caused by break in a proc 2017-08-30 12:25:55 +02:00
Yukihiro "Matz" Matsumoto 88cd807379 Avoid use of snprintf() when DISABLE_STDIO is set; fix #3632
ref #3492 #3515 #3517
2017-04-25 10:41:50 +09:00
ksss 7f983928b9 Reduce object allocation 2017-04-02 23:34:26 +09:00
ksss be5c304b4c Fix parameters when noname rest 2017-04-02 23:30:05 +09:00
Yukihiro "Matz" Matsumoto cea6a16cf4 Fixed some compiler errors regarding PRId. 2017-03-19 23:42:49 +09:00
Yukihiro "Matz" Matsumoto ef105b5ca4 Use MRB_PRId instead of "%d"; fix #3515 2017-03-19 20:43:25 +09:00
ksss 3cba13c249 Proc shouldn't have initialize method
Fix #3356
2016-12-21 15:17:05 +09:00
Francois Chagnon 1ec5994377 Fix calling .arity on Proc with undefined initialize
Reported by @bouk
2016-11-24 10:23:31 -05:00
Yukihiro "Matz" Matsumoto 5c405dea3d include changed from by quotes ("") to by brackets (<>); close #3032 2015-11-27 17:48:23 +09:00
Jun Hiroe 4e4929bc72 Rename extended xxxx class or module to xxxx class or module extension 2015-06-28 11:18:52 +09:00
Jun Hiroe c69d1201e1 Fix typo; Replace extensional with extended 2015-06-28 00:05:58 +09:00
cremno 69b4c1648a Proc#curry should preserve lambdas 2015-06-22 16:35:54 +02:00
Yukihiro "Matz" Matsumoto 471c43ff96 move mrb_proc_new_cfunc_with_env() to the core 2014-09-02 13:03:32 +09:00
Yukihiro "Matz" Matsumoto 206f89e209 add MRB_API modifiers to mruby API functions 2014-08-04 00:47:08 +09:00
ksss 9cafc5e105 Implement Proc#parameters 2014-06-25 16:05:33 +09:00
take_cheeze 2c451dd1fc Use assert_kind_of instead. 2014-05-24 23:18:03 +09:00
take_cheeze d8d07a2345 Move Kernel.local_variables to core. 2014-05-19 22:05:02 +09:00
take_cheeze 0f742392b5 Add ISO index to Kernel.local_variables. 2014-05-18 23:34:56 +09:00
Yukihiro "Matz" Matsumoto 41b46ca1ed register<nlocals may not have a local variable name (e.g. a block arg); fix #2258 2014-05-16 00:04:55 +09:00
Yukihiro "Matz" Matsumoto 27df1a84bc Kernel.local_variables to list UPVAR as well 2014-05-14 17:38:27 +09:00
take_cheeze 5073d14e28 Remove lv_len and use nlocals - 1 instead.
Check that `lv`'s length is always `nlocals - 1`.
2014-04-29 22:06:59 +09:00
take_cheeze 7ea82fedd5 Implement Kernel.local_variables for testing dumped local variables information. 2014-04-29 20:47:50 +09:00
Takeshi Watanabe 6e0c48d758 Fix and add test to Proc#inspect . 2014-04-14 22:01:52 +09:00
take_cheeze b38eb72d82 Add macro MRB_ENV_UNSHARE_STACK instead of assigning -1 directly. 2014-04-01 01:35:40 +09:00
take_cheeze 80534b6d14 Use MRB_ENV_STACK_LEN instead of accessing flags directly to get REnv's stack length. 2014-04-01 01:13:39 +09:00
take_cheeze bf6b1dfe21 Add API to define cfunc Proc with userdata.
The APIs are defined in mruby-proc-ext so include it before using this API.
See mruby-proc-ext's test code for usage.
This should resolve #1794.
2014-03-31 10:01:17 +09:00
take_cheeze c73f8d4def move summary of mrbgems in default gembox to its spec 2014-03-17 00:34:24 +09:00
Masaki Muranaka 270d25bf2d Make type casts safer. 2014-03-08 15:53:59 +09:00
take_cheeze f8270ee59b fix and add test for Proc#source_location 2014-03-06 03:40:41 +09:00
cubicdaiya a860735d0c use mrb_str_cat_lit() more widely 2014-02-26 03:03:47 +09:00
Yukihiro "Matz" Matsumoto ed1bf9aa80 introduce mrb_str_new_lit() to create strings from C string litrals 2014-02-06 07:50:34 +09:00
Yukihiro "Matz" Matsumoto 3995e7ff8f rename voidp to cptr 2013-09-21 17:28:47 +09:00
Daniel Bovensiepen 8936965945 Improve test of mruby-proc-ext GEM 2013-08-04 22:41:56 +08:00
Tomoyuki Sahara 116f75a8ce "spec.author" is better for single-author gems.
"spec.author=" expects a String represents a single author.
"spec.authors=" expects an Array which is a list of multiple authors.

http://guides.rubygems.org/specification-reference/
2013-07-23 10:09:24 +09:00
Yukihiro "Matz" Matsumoto 30d580ecbc rename every ARGS_XXX to MRB_ARGS_XXX; ref #1206 2013-04-25 09:47:36 +09:00
h2so5 1a375c6fd4 Add mruby-proc-ext 2013-04-17 22:59:57 +09:00