Hoshiumi Arata
|
612941dcbc
|
Add test code for even?/odd?
|
2024-07-23 21:09:17 +09:00 |
|
Hoshiumi Arata
|
80502b30fb
|
Optimize even?/odd? for big integers
|
2024-07-23 21:05:10 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
d2878138d9
|
mruby-numeric-ext: implement Integer#even? and Integer#odd?
|
2024-07-23 07:23:13 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
f3b570f33a
|
mruby-enumerator: add test for Enumerable#chunk_while
|
2024-07-22 13:52:12 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
dcbe2e3eb3
|
mruby-enumerator: add Enumerable#chunk_while
|
2024-07-21 20:29:27 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
7d8fc3b35f
|
Merge pull request #6305 from dearblue/method_missing
Protect keyword arguments in `prepare_missing()`
|
2024-07-20 22:04:50 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
9326c514c5
|
mruby-enum-ext: add Enumerable#each_entry test
|
2024-07-20 14:20:15 +09:00 |
|
Pete Kinnecom
|
509590c18d
|
Method missing kwargs test failure:
Fail: Method#call with undefined method -- only kwargs (mrbgems: mruby-method)
- Assertion[6]
NoMethodError exception expected, not
Class: <TypeError>
Message: <Array cannot be converted to Hash>
- Assertion[9]
Expected: {:kwarg1=>:val1, :kwarg2=>:val2}
Actual: [:foo]
|
2024-07-19 20:37:40 +00:00 |
|
Yukihiro "Matz" Matsumoto
|
c539256b43
|
mruby-enum-ext: add Enumerable#each_entry
|
2024-07-19 23:29:45 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
45078d9a49
|
mruby-string-ext: fixed typo (casecmp! -> casecmp?)
|
2024-07-17 02:25:49 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
ca28e639c6
|
mruby-numeric-ext: move allbits?, anybits?, nobits? to Integer class
|
2024-07-15 21:35:42 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
3f5138a6ac
|
mruby-numeric-ext: implement Numeric#integer? method
|
2024-07-15 21:35:42 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
1a8df40392
|
mruby-enum-ext: add Array#sort_by! method
|
2024-07-15 21:35:42 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
fcab7ef377
|
numeric.c (int_div): fixed a bug regarding bigint / non-integer
Non-integer means Complex or Rational.
|
2024-07-15 21:35:42 +09:00 |
|
John Bampton
|
de8a6fe787
|
Fix spelling
|
2024-07-13 00:21:53 +10:00 |
|
Yukihiro "Matz" Matsumoto
|
c75f7587bc
|
mruby-numeric-ext: add call-seq reference for Integer#size
|
2024-07-10 14:56:13 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
ee296f024b
|
mruby-numeric-ext: add Integer#size method
Although CRuby uses clz() for the biggest word, mruby bigint only counts
number of digit words.
|
2024-07-10 14:50:54 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
a77bc25a5f
|
mruby-sprintf: support dots expression of negative integer format
For specifiers assume unsigned integers, negative numbers show dots (..)
to indicate virtual infinite 1s at the MSB side of 2's compliment.
|
2024-07-09 11:13:55 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
80fec16cb6
|
mruby-sprintf: inline sign_bits() function
|
2024-07-09 10:48:07 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
d249c2e939
|
mruby-sprintf: separate filling high bits and converting negatives
|
2024-07-09 10:40:46 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
2488375a35
|
mruby-bigint (mpz_mod): move mpz_init() to avoid memory leak
|
2024-07-09 08:00:23 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
0ea1549faa
|
mruby-sprintf: reorder functions
In addition, internal function `mrb_str_format()` is made `static`.
|
2024-07-06 08:45:19 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
bd502f6d7b
|
mruby-sprintf: support Big integers for %d etc.
|
2024-07-04 22:51:14 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
f1a04dae3e
|
mruby-enum-ext (sort_by): avoid copying the receiver
When the receiver is an Array.
|
2024-07-03 07:31:32 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
eee83ed7af
|
array.c: implement Array#index and Array#rindex in C
No need to override Array#index in mruby-array-ext. We can call
`to_enum` from C implemented methods.
|
2024-06-29 15:03:12 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
75de002058
|
mruby-complex: provide Complex#<=> in Ruby
|
2024-06-17 08:14:27 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
3b9aec90dd
|
mruby-rational: define <=> method in Ruby, not in C
|
2024-06-17 08:02:42 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
36eff3ec59
|
mruby-rational/test: remove UserDefinedNumeric tests
Since they checks the behavior different from CRuby.
|
2024-06-17 07:57:54 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
b44dc1c0b9
|
mruby-rational: use presym for initialization
|
2024-06-14 06:17:20 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
0e045a52f6
|
mruby-complex: use presym for initialization
|
2024-06-14 06:15:34 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
921a54ef33
|
mruby-socket/socket.rb: done some small refactoring
|
2024-06-14 06:14:27 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
39d577799f
|
mruby-socket: use presym for initialization
|
2024-06-14 06:14:07 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
7be10097a0
|
mruby-io: use presym for initialization
|
2024-06-14 02:00:17 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
db8d43090a
|
mruby-struct: use presym for initialization
|
2024-06-14 01:59:30 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
8bd66a9358
|
mruby-data: use presym for initialization
|
2024-06-14 01:59:10 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
d5fd3338a4
|
mruby-method: use presym for initialization
|
2024-06-14 01:46:22 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
71a4e5f3ff
|
mruby-proc-ext: use presym for initialization
|
2024-06-14 01:45:58 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
2b4591fe68
|
mruby-proc-binding: use presym for initialization
|
2024-06-14 01:45:23 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
9fbdf78380
|
mruby-binding: use presym for initialization
|
2024-06-14 01:44:49 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
d1e49f7121
|
mruby-metaprog: use presym for initialization
|
2024-06-14 01:43:57 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
c32a94d878
|
mruby-string-ext: use presym for initialization
|
2024-06-14 01:43:03 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
513908d77f
|
mruby-range-ext: use presym for initialization
|
2024-06-14 01:42:30 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
4104837ba1
|
mruby-hash-ext: use presym for initialization
|
2024-06-14 01:41:55 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
cfd90a65f7
|
mruby-array-ext: use presym for initialization
|
2024-06-14 01:41:06 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
574f9f0d39
|
mruby-class_ext: use presym for initialization
|
2024-06-14 00:37:05 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
6361f6d661
|
mruby-numeric-ext: use presym for initialization
|
2024-06-14 00:35:44 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
d94916bf15
|
mruby-kernel-ext: use presym for initialization
|
2024-06-14 00:34:07 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
e1a62a581f
|
mruby-object-ext: use presym for initialization
|
2024-06-14 00:33:18 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
c99b8d7d3b
|
mruby-fiber: use presym for initialization
|
2024-06-14 00:32:07 +09:00 |
|
Yukihiro "Matz" Matsumoto
|
bf8e19f7da
|
mruby-sleep: use presym for initialization
|
2024-06-14 00:30:32 +09:00 |
|