| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
| |
Repaired What's Here sections for Range, String, Symbol, Struct.
|
| |
|
|
|
|
|
|
|
|
|
| |
Previously, include? would return true for the end of the range,
when it should return false because the range is exclusive.
Research and Analysis by Victor Shepelev.
Fixes [Bug #18577]
|
|
|
|
|
| |
Once https://github.com/ruby/rdoc/pull/865 is merged, these hacks
are no longer needed.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
I used this regex:
(?<=\[)#(?:class|module)-([A-Za-z]+)-label-([A-Za-z0-9\-\+]+)
And performed a global find & replace for this:
rdoc-ref:$1@$2
|
|
|
|
|
|
|
|
|
|
| |
I used this regex:
([A-Za-z]+)\.html#(?:class|module)-[A-Za-z]+-label-([A-Za-z0-9\-\+]+)
And performed a global find & replace for this:
rdoc-ref:$1@$2
|
|
|
|
| |
* Adding links to literals and Kernel
|
|
|
|
|
|
|
| |
* Some code replace and using RBOOL macro
* Fix indent
* Using RBOOL in syserr_eqq function
|
|
|
|
| |
Code markup in RDoc must not be concatenated with anothr word.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In commit:7817a438eb1803e7b3358f43bd1f38479badfbdc, the implementation
of `Time#succ`, which had been deprecated for 10 years, was finally
removed.
During that time, there was an explicit `instance_of?` check in
source:range.c#L350 with a comment that the check should be removed
once `Time#succ` is removed.
Since `Time#succ` is now gone, this check should be removed.
Note: this should be coordinated with adding a version guard to the
corresponding check in ruby/spec as well.
|
| |
|
| |
|
|
|
| |
Introductory material revised.
|
|
|
|
|
|
|
|
|
|
|
| |
Treated:
#to_s
#inspect
#===
#include?
#cover?
#count
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
* As the "doc/" prefix is specified by the `--page-dir` option,
remove from the rdoc references.
* Refer to the original .rdoc instead of the converted .html.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Treated:
#size
#to_a
#each
#begin
#end
#first
#last
|
|
|
| |
This PR creates doc/bsearch.rdoc to provide common documentation for bsearch in Array and Range.
|
|
|
|
|
|
|
|
|
|
|
| |
Treated:
::new
#include_end?
#==
#eql?
#hash
#step
|
| |
|
| |
|
| |
|
|
|
|
| |
This way the header flags and object internals are set correctly
|
|
|
|
|
|
|
|
|
| |
* numeric.c: prohibit zero step in Numeric#step
* range.c: prohibit zero step in Range#step
* Fix ruby-spec
[Feature #15573]
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Support ArithmeticSequence in Array#slice
* Extract rb_range_component_beg_len
* Use rb_range_values to check Range object
* Fix ary_make_partial_step
* Fix for negative step cases
* range.c: Describe the role of err argument in rb_range_component_beg_len
* Raise a RangeError when an arithmetic sequence refers the outside of an array
[Feature #16812]
|
|
|
|
| |
[Bug #17271]
|
|
|
|
|
| |
Matz want to try to freeze all Range objects.
[Feature #15504]
|
| |
|
| |
|
|
|
|
|
|
| |
non-integer end"
This reverts commit 8900a25581822759daca528d46a75e0b743fc22e.
|
|
|
|
| |
This reverts commit 05bf811c2839628aaef3d565daedb28be80d47ef.
|
|
|
|
|
|
|
|
|
| |
Popular Ruby libraries such as Rails and Rubocop relying on the
previous behavior, even though it is technically a bug. The
correct behavior is probably raising RangeError, since that is what
an endless range raises.
Related to [Bug #17017]
|
|
|
|
|
|
|
|
|
| |
* Fix Range#max for beginless Integer ranges
* Update test/ruby/test_range.rb
* Fix formatting
https://github.com/ruby/ruby/pull/3328
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, for inclusive ranges, the max would show up as the
end of the range, even though the end was not an integer and would
not be the maximum value. For exclusive ranges, max/minmax would
previously raise a TypeError, even though it is possible to get the
correct maximum.
This change to max/minmax also uncovered a similar error in cover?,
which calls max in certain cases, so adjust the code there so that
cover? still works as expected.
Fixes [Bug #17017]
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The implementation of Range#minmax added in d5c60214c45 causes the
following incorrect behaviour:
('a'...'c').minmax => ["a", ["a", "b"]]
instead of
('a'...'c').minmax => ["a", "b"]
This is because the C implementation of Range#minmax (range_minmax)
directly delegates to the C implementation of Range#min (range_min) and
Range#max (range_max), without changing the execution context.
Range#max's C implementation (range_max), when given a non-numeric
exclusive range, delegates to super, which is meant to call
Enumerable#max. However, because range_max is called directly by
range_minmax, super calls Enumerable#minmax instead, causing the
incorrect nesting.
Perhaps it is possible to change the execution context in an optimized
manner, but the simplest solution seems to be to just explicitly
delegate from Range#minmax to Range#min and Range#max.
|
|
|
|
|
|
| |
Not every compilers understand that rb_raise does not return. When a
function does not end with a return statement, such compilers can issue
warnings. We would better tell them about reachabilities.
|
|
|
|
|
| |
I'm not necessarily against every goto in general, but jumping into a
branch is definitely a bad idea. Better refactor.
|
|
|
|
| |
To fix build failures.
|
|
|
|
| |
This shall fix compile errors.
|
| |
|