Commit Graph

4254 Commits

Author SHA1 Message Date
Yukihiro "Matz" Matsumoto e202d4cd53 add src/error.h for compatibility reason 2014-02-22 23:38:59 +09:00
Yukihiro "Matz" Matsumoto e8daace8f1 Merge pull request #1724 from h2so5/f2s-significand
preserve significands in float-string conversion
2014-02-22 18:06:27 +09:00
h2so5 b0e3b873f5 preserve significands in float-string conversion 2014-02-22 16:50:52 +09:00
Yukihiro "Matz" Matsumoto ac936fc211 powered num may be infinite in float-string conversion 2014-02-22 11:06:38 +09:00
Yukihiro "Matz" Matsumoto 6b6c590fe3 Merge pull request #1722 from take-cheeze/hash_ext_arena_fix
Fix possible arena overflow in mruby-hast-ext.
2014-02-22 10:55:04 +09:00
Yukihiro "Matz" Matsumoto 96e806ff05 Merge pull request #1723 from akuroda/string_test_cap_down
add tests for String#capitalize!, String#downcase!, and String#upcase!
2014-02-22 10:51:13 +09:00
Akira Kuroda 61523d0e4f fix the position of capitalize! and downcast!, and add test for upcase! 2014-02-22 00:43:12 +09:00
take_cheeze 658b4f4ea7 add test(requires MRB_GC_FIXED_ARENA enabled) 2014-02-22 00:28:38 +09:00
Akira Kuroda f6516526b5 add tests for String#capitalize! and String#downcase! 2014-02-22 00:19:29 +09:00
take_cheeze a9af8c9c07 fix possible arena overflow 2014-02-22 00:05:05 +09:00
Yukihiro "Matz" Matsumoto 36e234aa37 Merge pull request #1720 from take-cheeze/move_error_h
move src/error.h to include/mruby/error.h
2014-02-21 11:02:36 +09:00
take_cheeze 08ea324593 move src/error.h to include/mruby/error.h 2014-02-20 22:41:29 +09:00
Yukihiro "Matz" Matsumoto 66ecd159d3 Merge pull request #1719 from pbosetti/master
Added spaces in version.h macros for complying with C++11
2014-02-18 21:35:56 +09:00
Paolo Bosetti 0b603baa53 Added spaces in version.h macros for complying with C++11 2014-02-17 17:54:49 +01:00
Yukihiro "Matz" Matsumoto 800d992987 Merge pull request #1717 from cremno/iv_size-t-null
iv_size (non-seglist): return 0 if t is NULL
2014-02-18 00:30:07 +09:00
cremno 69bc004e08 iv_size (non-seglist): return 0 if t is NULL 2014-02-17 12:39:56 +01:00
Yukihiro "Matz" Matsumoto 57b7f6b619 use double instead of mrb_float (that may be single precision float) to reduce errors 2014-02-17 10:20:58 +09:00
Yukihiro "Matz" Matsumoto eacdcc13d8 remove trailing zeros from float string representation 2014-02-17 10:11:51 +09:00
Yukihiro "Matz" Matsumoto a740b28b52 define FLO_EPSILON depends on float/double 2014-02-17 09:47:39 +09:00
Yukihiro "Matz" Matsumoto 4b981adc58 remove max_digit from mrb_flo_to_str() 2014-02-17 09:40:30 +09:00
Yukihiro "Matz" Matsumoto ffe541b503 small refactoring; direct return 2014-02-17 09:35:20 +09:00
Yukihiro "Matz" Matsumoto 25ea4d751b use powf() instead of pow() on MRB_USE_FLOAT 2014-02-17 09:34:56 +09:00
Yukihiro "Matz" Matsumoto b4bc395680 fdigit may be negative due to error if mrb_float is 32bit (e.g. 10**36 on 32bit arch); ref #1713 #1714 2014-02-17 09:27:53 +09:00
Yukihiro "Matz" Matsumoto 09080fd2ee Merge pull request #1714 from h2so5/f2s
fix mrb_flo_to_str() exponent problem
2014-02-17 07:57:12 +09:00
h2so5 db80a9a2ce fix mrb_flo_to_str() exponent problem 2014-02-17 07:53:02 +09:00
Yukihiro "Matz" Matsumoto 41a77111ea Merge pull request #1710 from takkaw/flo_to_str
modify mrb_to_str() in order to display big float number
2014-02-16 01:33:43 +09:00
Yukihiro "Matz" Matsumoto e29efb02bd normalize NaN after division that may generate NaN; fix #1712 2014-02-15 19:59:26 +09:00
takkaw 0a48fb0407 modify mrb_to_str() in order to display big float number 2014-02-15 15:40:51 +09:00
Yukihiro "Matz" Matsumoto 8b93f8591d Merge pull request #1709 from cubicdaiya/issues/nonvoid
Give the type 'void' to functions have no argument.
2014-02-15 13:25:41 +09:00
cubicdaiya 3d716f2376 Give the type 'void' to functions have no argument.
According to the C standard,
it is desirable to give the type 'void'
to functions have no argument.
2014-02-14 19:47:15 +09:00
Yukihiro "Matz" Matsumoto 7586d474b5 Merge pull request #1707 from Fleurer/issue1706
keep stack with nlocals instead of nregs; fix #1706
2014-02-14 17:06:43 +09:00
Yukihiro "Matz" Matsumoto 007ed07e77 Merge pull request #1708 from Fleurer/cleanup-warning-hash-dup
cleanup warnings in hash.c
2014-02-14 17:04:21 +09:00
Li Yazhou 7ab0506795 add test for Hash#dup 2014-02-14 13:26:19 +08:00
Li Yazhou adbf1eba99 clearn up warning in hash.c
/home/fleuria/code/mruby/src/hash.c:159:1: warning: ‘mrb_hash_dp`defined but not used [-Wunused-function]
 mrb_hash_dup(mrb_state *mrb, mrb_value hash)
     ^

this commit defines Hash#dup to take advantage of mrb_hash_dup, however
it seems that Hash#dup is not in ISO standard.
2014-02-14 13:22:30 +08:00
Li Yazhou 876e7de7ec add a regression test for #1706 2014-02-14 11:32:59 +08:00
Li Yazhou 9ebfeac111 keep stack with nlocals instead of nregs; fix #1706 2014-02-14 11:16:56 +08:00
Yukihiro "Matz" Matsumoto ba8a8e75c7 Merge pull request #1702 from cremno/hash-hash-ext-changes
hash / hash-ext: various small changes
2014-02-14 01:29:19 +09:00
Yukihiro "Matz" Matsumoto 69eaaa146c Merge pull request #1705 from takahashim/version-number
MRUBY_VERSION should be only numbers separated by dot, like JRUBY_VERSION or Rubinius::VERSION
2014-02-14 01:27:05 +09:00
Yukihiro "Matz" Matsumoto 9ad55617c3 Merge pull request #1703 from cremno/parenthesize-mrbdump-errnos
dump.h: parenthesize negative errnos
2014-02-14 01:26:13 +09:00
Yukihiro "Matz" Matsumoto bc8c803990 Merge pull request #1704 from cremno/rm-mrb_str_literal-decl
remove mrb_str_literal declaration
2014-02-14 01:25:54 +09:00
Yukihiro "Matz" Matsumoto 22d5102504 Merge pull request #1701 from cremno/do-not-use-mrb_str_cat2
mrb_str_cat2: deprecated since 0cedf8f
2014-02-14 01:25:17 +09:00
takahashim ac4443879a MRUBY_VERSION should be only numbers separated by dot, like JRUBY_VERSION or Rubinius::VERSION 2014-02-13 22:19:42 +09:00
cremno 8bbc2c107b mrb_str_cat2: deprecated since 0cedf8f 2014-02-13 13:45:28 +01:00
cremno 5a76288f3f remove mrb_str_literal declaration
definition was removed in 677a2ac
2014-02-13 13:39:44 +01:00
cremno e8945b8598 dump.h: parenthesize negative errnos 2014-02-13 13:39:22 +01:00
cremno 4ffea85b62 hash / hash-ext: various small changes
src/hash.c:
 - mrb_hash_(aget|aset|dup|delete): internal linkage
 - remove documentation of methods which are not implemented (in here)
 - remove #assoc; unused, not in ISO spec
 - remove #rassoc: same, implementation is also wrong

hash-ext mrbgem:
 - remove header "mruby/khash.h"
 - remove mrb_hash_values_at (move code into hash_values_at, i: long -> int)
 - less whitespace in gem_init function
2014-02-13 13:39:09 +01:00
Yukihiro "Matz" Matsumoto 7a32c7b183 remove direct inclusion of mruby/version.h from version.c; #1698 2014-02-13 00:45:56 +09:00
Tomoyuki Sahara 50ef284015 include mruby/version.h in mruby.h 2014-02-12 10:26:19 +09:00
Yukihiro "Matz" Matsumoto 26781692b7 Merge pull request #1697 from cremno/array-changes
array implementation: several small changes
2014-02-12 09:31:28 +09:00
Yukihiro "Matz" Matsumoto 4558b29719 Merge pull request #1694 from cremno/rakefile-mkdir-bin-path
Rakefile: make bin directory
2014-02-12 09:28:50 +09:00