Commit Graph

847 Commits

Author SHA1 Message Date
Yukihiro "Matz" Matsumoto 95c7f570e1 change class argument of mrb_const_defined_at from struct RClass* to mrb_value to make it consistent with mrb_const_defined; ref #2593 2014-09-19 02:51:52 +09:00
Yukihiro "Matz" Matsumoto 50f54529f2 to_hash/to_a check in Hash[] should only be done when only one argument is given; ref #2594 2014-09-19 01:14:50 +09:00
Yukihiro "Matz" Matsumoto 02b2ac8de2 Merge pull request #2594 from yasuyuki/hash
Implement Hash[]
2014-09-19 00:36:33 +09:00
INOUE Yasuyuki 5f16c41753 copy documentation comment from CRuby 2014-09-18 17:43:38 +09:00
INOUE Yasuyuki d30aadf306 remove line number from raise message 2014-09-18 17:37:48 +09:00
INOUE Yasuyuki e66d86a5fb refactor Hash generator loop 2014-09-18 16:07:27 +09:00
Yukihiro "Matz" Matsumoto 48c5321dca constify pointer from RARRAY_PTR to detect potential write barrier bugs.
if you see compiler errors due to this commit, you'd better to use array-modifying
functions, e.g. mrb_ary_set() or mrb_ary_push(), otherwise you might see nasty
GC bugs in the future.  if you are sure what you are doing, replace `RARRAY_PTR(ary)`
by `mrb_ary_ptr(ary)->ptr`. but be warned.
2014-09-12 12:42:39 +09:00
INOUE Yasuyuki 5603b8d79f implement Hash.[] 2014-09-06 22:50:06 +09:00
Yukihiro "Matz" Matsumoto 33e44a612c refactor MACRO to avoid local variable name conflict; ref #2585 2014-09-04 23:59:27 +09:00
cremno fec2c66ea8 get rid of shadowing variables (mrbgems)
Mostly renaming, except that the definition of struct accessor methods
is now done in a new function.
2014-09-04 12:31:52 +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 9e4b012478 Merge pull request #2570 from cubicdaiya/issues/unify_duplicated_functions
Unify and rename duplicated functions (noregexp() and regexp_check()).
2014-08-29 01:09:33 +09:00
Tatsuhiko Kubo 5fa30aeaea Fix mismatches for MRB_API declarations. 2014-08-29 01:06:22 +09:00
Tatsuhiko Kubo db29a25ada Rename functions for avoinding symbol confiliction.
Add prefix(mrb) to noregexp() and regexp_check().
2014-08-28 19:18:52 +09:00
Tatsuhiko Kubo d958aa2cb1 Unify duplicated functions (noregexp() and regexp_check()). 2014-08-28 19:13:57 +09:00
Tatsuhiko Kubo 6961317fb3 Remove spaces in end-of-line. 2014-08-25 16:49:15 +09:00
Tatsuhiko Kubo 6c7ba826dd Use sizeof() instead of strlen(). 2014-08-22 20:37:34 +09:00
bggd dc1dcba935 Update math.c 2014-08-22 16:51:04 +09:00
Yukihiro "Matz" Matsumoto 5aa6f8ba96 Merge pull request #2551 from cubicdaiya/issues/use_mrb_str_cat_lit
use mrb_str_cat_lit() instead of mrb_str_cat_cstr().
2014-08-22 00:31:00 +09:00
Tatsuhiko Kubo 45103ebc20 use mrb_str_cat_lit() instead of mrb_str_cat_cstr(). 2014-08-21 16:51:08 +09:00
kkkkkt d94469ac23 changed to call check_cv_name_str in check_cv_name_sym and adjust indent 2014-08-21 13:56:43 +09:00
Yukihiro "Matz" Matsumoto 4d72d65db1 Merge pull request #2548 from take-cheeze/mrb_data_init
Add API `mrb_data_init` to initialize `MRB_TT_DATA` tagged instance.
2014-08-20 23:42:05 +09:00
take_cheeze b3d0585fe5 Add API mrb_data_init to initialize MRB_TT_DATA tagged instance. 2014-08-20 22:42:35 +09:00
Tatsuhiko Kubo 2b283393c6 Remove empty lines. 2014-08-20 12:07:36 +09:00
Tatsuhiko Kubo e035508efd Fix error handling for mrb_generate_code().
The return value of mrb_generate_code()
must be null-checked before referencing.
2014-08-19 17:50:07 +09:00
Tatsuhiko Kubo 55ee7fe79c Fix error handlings in mirb.
mrb_parser_new() and mrb_generate_code() may return NULL.
2014-08-19 16:04:48 +09:00
chasonr e23deaafc2 Improve replacement math functions for Visual C++. 2014-08-15 23:15:45 -04:00
mattn 4ece1e3e29 "-a-a-".succ should be "-a-b-" 2014-08-11 15:00:44 +09:00
mattn 3103d063e2 Fix String#succ. "-a-".succ should be "-b-" 2014-08-11 14:28:05 +09:00
mattn 34f40b0a01 Fix String#succ. "-".succ should be "." 2014-08-11 14:01:10 +09:00
dycoon e7249e4590 timer on windows bug fixed. 2014-08-09 21:40:52 +09:00
Yukihiro "Matz" Matsumoto 7a5d3c19c6 remove test for succ on Unicode (non-ASCII) char; #2520 2014-08-08 23:16:12 +09:00
Yukihiro "Matz" Matsumoto 0381de3ee6 Merge branch 'string-succ' of https://github.com/mattn/mruby into mattn-string-succ 2014-08-08 23:15:14 +09:00
mattn dc0c354658 Add String#succ, String#succ!, String#next, String#next! 2014-08-08 17:58:07 +09:00
Satoshi Odawara 432e8e9ea9 fixed evaluation context of eval(string) and instance_eval(string) 2014-08-08 16:59:40 +09:00
Yukihiro "Matz" Matsumoto 569c7dec5f move StopIteration to core; close #2518 2014-08-08 16:08:53 +09:00
Yukihiro "Matz" Matsumoto 8dbf7787d5 Merge pull request #2510 from cremno/mruby-strip-use-mrb_open_core
mruby-strip doesn't need mrbgems
2014-08-06 11:48:10 +09:00
kkkkkt 9c78fc8443 added Math.cos and Math.tan test case 2014-08-05 11:27:50 +09:00
cremno cc4c22c5f5 mruby-strip doesn't need mrbgems
Reduces executable size by more than 50% (409->171 KB).
2014-08-04 12:26:36 +02:00
Yukihiro "Matz" Matsumoto 206f89e209 add MRB_API modifiers to mruby API functions 2014-08-04 00:47:08 +09:00
Yukihiro "Matz" Matsumoto 0878900fda Time#to_i and Time#usec should care about mrb_int overflow on MRB_INT16; ref #2495 2014-08-03 20:36:20 +09:00
Yukihiro "Matz" Matsumoto 16ddb16608 Merge pull request #2462 from cremno/mirb-malloc-history_path
mirb: allocate `history_path` dynamically
2014-07-30 08:41:26 +09:00
Yukihiro "Matz" Matsumoto 4b69121284 restore mrb_get_args() in f_instance_eval to check arguments type 2014-07-22 08:38:38 +09:00
Yukihiro "Matz" Matsumoto 7457da6aa1 exception in instance_eval should not exit mrb_run; fix #2483 2014-07-22 07:29:26 +09:00
Yukihiro "Matz" Matsumoto ce7dfe97ad Merge pull request #2475 from take-cheeze/full_core_list
Check mrbgem.rake instead of directory to ignore empty directories in full-core gembox.
2014-07-17 01:28:36 +09:00
take_cheeze 568b2c79b1 Check mrbgem.rake instead of directory to ignore empty directories in full-core. 2014-07-16 22:49:06 +09:00
Yukihiro "Matz" Matsumoto 2dcc2444fa need to call write_barrier on every fiber context switch 2014-07-16 12:58:37 +09:00
Yukihiro "Matz" Matsumoto abf52c7773 remove unused local variables; ref #2473 2014-07-16 05:21:55 +09:00
take_cheeze dd34decdfc Implement string compiling instance_eval method. 2014-07-15 22:33:14 +09:00
Yukihiro "Matz" Matsumoto d5dd3e9472 fiber stack allocation size should be bigger than irep->nregs 2014-07-15 17:17:58 +09:00