| Age | Commit message (Collapse) | Author |
|
zubycz-work_for_merge
|
|
Co-Authored-By: n4o847 <[email protected]>
Co-Authored-By: smallkirby <[email protected]>
|
|
* The `Fixnum` constant is now an alias for the `Integer` class.
* Remove `struct mrb_state::fixnum_class` member.
If necessary, use `struct mrb_state::integer_class` instead.
|
|
|
|
Before this patch:
$ bin/mruby -e 'p (2...4.0).min' #=> TypeError
After this patch (same as CRuby and without `mruby-range-ext`):
$ bin/mruby -e 'p (2...4.0).min' #=> 2
|
|
|
|
|
|
If no block is given and the Range has Fixnum or Float endpoints, do not iterate with
each and instead compare the endpoints directly. This implementation passes all of
the applicable specs from Ruby Spec.
|
|
The ISO standard does not include implicit type conversion using
`to_int`. This implicit conversion often causes vulnerability.
There will be no more attacks like #4120.
In addition, we have added internal convenience method `__to_int` which
does type check and conversion (from floats).
|
|
|
|
Range#first shouldn't call `Range#to_a` on infinity range.
|