cremno
89b27648dd
add symbol table overflow check
...
Since raising an error might intern a few new strings, some symbols need
to be reserved. 8 should be sufficient.
If the real limit has been reached, mrb_bug() is called.
2014-08-27 12:51:10 +02:00
Yukihiro "Matz" Matsumoto
ecda19f402
Merge pull request #2565 from cremno/remove-unused-msvc-strtoll-fallback
...
remove unused MSVC strtoll fallback
2014-08-26 09:16:46 +09:00
Yukihiro "Matz" Matsumoto
d0ced41f6e
Merge pull request #2563 from cremno/printf-cast-variables-to-expected-type
...
printf: cast variables to the expected type
2014-08-26 09:16:25 +09:00
Yukihiro "Matz" Matsumoto
3979dd0250
Merge pull request #2564 from cremno/use-mrb_stringize
...
use MRB_STRINGIZE
2014-08-26 09:15:50 +09:00
cremno
3ac4c24534
remove unused MSVC strtoll fallback
2014-08-26 00:52:31 +02:00
cremno
bdaa12de1d
use MRB_STRINGIZE
...
It's defined in mruby/version.h which gets included in mruby.h, so it's
safe to use.
2014-08-26 00:32:06 +02:00
cremno
bdf6ce34ce
printf: cast variables to the expected type
...
%x expects unsigned int and %p expects void *
GCC emits a diagnostic about %p/void* in pedantic mode:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26542
2014-08-26 00:30:33 +02:00
Yukihiro "Matz" Matsumoto
73a012c808
Merge pull request #2561 from cubicdaiya/issues/space_EOL
...
Remove spaces in end-of-line.
2014-08-26 02:25:05 +09:00
Yukihiro "Matz" Matsumoto
ecc77829ce
Merge pull request #2562 from cubicdaiya/issues/pow_flo
...
Fix and add test for Numeric#pow behavior.
2014-08-26 02:24:18 +09:00
Tatsuhiko Kubo
bd6dc0da77
Add test for Numeric#pow.
2014-08-25 17:18:24 +09:00
Tatsuhiko Kubo
0e9f98c430
Fix Numeric#pow behavior.
...
* Before
2 ** -1 #=> 0
* After
2 ** -1 #=> 0.5
2014-08-25 17:17:37 +09:00
Tatsuhiko Kubo
6961317fb3
Remove spaces in end-of-line.
2014-08-25 16:49:15 +09:00
Yukihiro "Matz" Matsumoto
b01b3c4472
Merge pull request #2555 from cubicdaiya/issues/reduce_strlen
...
Use sizeof() instead of strlen().
2014-08-22 20:42:47 +09:00
Tatsuhiko Kubo
6c7ba826dd
Use sizeof() instead of strlen().
2014-08-22 20:37:34 +09:00
Yukihiro "Matz" Matsumoto
84b245066e
Merge pull request #2553 from bggd/patch-6
...
Fix build failed on VS2012
2014-08-22 20:04:47 +09:00
bggd
dc1dcba935
Update math.c
2014-08-22 16:51:04 +09:00
Yukihiro "Matz" Matsumoto
e3d92d8cf8
Merge pull request #2552 from cubicdaiya/issues/eval_return_value_mrb_method_search
...
Remove a discarded comparison.
2014-08-22 07:56:12 +09:00
Yukihiro "Matz" Matsumoto
26398996f9
Merge pull request #2550 from cubicdaiya/issues/unify_include_guards
...
Unify include guard styles and header comments.
2014-08-22 07:55:38 +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
Yukihiro "Matz" Matsumoto
015087c57f
Merge pull request #2549 from kkkkkt/fix_indent_and_refactor
...
changed to call check_cv_name_str in check_cv_name_sym and adjust indent
2014-08-21 23:13:24 +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
Tatsuhiko Kubo
3b904e9408
Unify include guard styles and header comments.
2014-08-21 13:27:37 +09:00
Tatsuhiko Kubo
3f685533b8
Remove a discarded comparison.
...
mrb_method_search() does not return NULL.
Instead it raises an exception.
So it is not necessary to evaluate
a return value of mrb_method_search().
2014-08-21 12:43:20 +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
Yukihiro "Matz" Matsumoto
ae28365341
Merge branch 'master' of github.com:mruby/mruby
2014-08-20 23:39:48 +09:00
Yukihiro "Matz" Matsumoto
e73a091343
Merge branch 'cubicdaiya-issues/scope_new_error_handlings'
2014-08-20 23:38:49 +09:00
Yukihiro "Matz" Matsumoto
05ede52239
should use non NULL scope for raise_error(); ref #2547
2014-08-20 23:38:37 +09:00
Yukihiro "Matz" Matsumoto
399f88fa7b
Merge pull request #2546 from cubicdaiya/issues/emptylines
...
Remove empty lines.
2014-08-20 23:34:37 +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
ae2d49811a
Fix allocation-error-handlings for scope_new().
2014-08-20 12:25:29 +09:00
Tatsuhiko Kubo
2b283393c6
Remove empty lines.
2014-08-20 12:07:36 +09:00
Yukihiro "Matz" Matsumoto
f6f31a8ecd
Merge pull request #2545 from cubicdaiya/issues/use_null_insteadof_zero
...
Use specified macro(NULL) instead of magic-number.
2014-08-20 09:26:46 +09:00
Yukihiro "Matz" Matsumoto
1251b0d5c9
Merge pull request #2542 from cubicdaiya/issues/mrb_pool_realloc_error_handlings
...
Fix error handling for mrb_pool_realloc().
2014-08-20 09:26:11 +09:00
Yukihiro "Matz" Matsumoto
bceaade168
Merge pull request #2543 from cubicdaiya/issues/mrb_open_allocf_error_handlings
...
Fix error handling for mrb_open_allocf().
2014-08-20 09:25:33 +09:00
Yukihiro "Matz" Matsumoto
28cf769a6e
Merge pull request #2544 from cubicdaiya/issues/mrb_open_core_error_handling
...
Fix error handlings for mrb_open_core().
2014-08-20 09:25:10 +09:00
Tatsuhiko Kubo
effc44f265
Fix error handlings for mrb_open_core().
2014-08-20 05:48:09 +09:00
Tatsuhiko Kubo
53a7549e1c
Fix error handling for mrb_open_allocf().
...
When DISABLE_GEMS is not defined and
a return value of mrb_open_core() is NULL,
mrb_open_allocf() may cause SEGV.
2014-08-20 05:15:21 +09:00
Tatsuhiko Kubo
5ee00453e0
Fix error handling for mrb_pool_realloc().
...
mrb_pool_alloc() may return NULL.
2014-08-20 05:07:40 +09:00
Tatsuhiko Kubo
ae306793f2
Use specified macro(NULL) instead of magic-number.
2014-08-20 04:34:03 +09:00
Yukihiro "Matz" Matsumoto
d49f8517a6
Merge pull request #2540 from cubicdaiya/issues/read_irep_record_error_handlings
...
Fix error hanldlings in read_irep_record().
2014-08-19 21:52:23 +09:00
Yukihiro "Matz" Matsumoto
c7fda2232b
Merge pull request #2541 from cubicdaiya/issues/codegen_error_handling
...
Fix error handling for mrb_generate_code().
2014-08-19 20:11:59 +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
ff9582833d
Fix error hanldlings in read_irep_record().
...
read_irep_record_1() and read_irep_record() may return NULL.
2014-08-19 17:42:20 +09:00
Yukihiro "Matz" Matsumoto
f62dc56ba2
Merge pull request #2539 from cubicdaiya/issues/mirb_error_handlings
...
Fix error handlings in mirb.
2014-08-19 16:18:06 +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
Yukihiro "Matz" Matsumoto
444e4b7976
Merge pull request #2538 from kkkkkt/refactor-method
...
refactor mruby method(fix indent. remove temporary value etc)
2014-08-19 10:32:39 +09:00
kkkkkt
2f1d12c717
revert mrb_equal method
2014-08-18 18:54:46 +09:00
kkkkkt
9da37cdfd1
refactor mruby method(fix indent. remove temporary value, duplicate procedure)
2014-08-18 10:58:48 +09:00
Yukihiro "Matz" Matsumoto
98a95530c2
Merge pull request #2537 from chasonr/math-functions
...
Improve replacement math functions for Visual C++.
2014-08-16 17:56:02 +09:00