aboutsummaryrefslogtreecommitdiffstats
path: root/array.c
Commit message (Collapse)AuthorAgeFilesLines
* RARRAY_AREF: convert into an inline function卜部昌平2020-08-151-1/+1
| | | | | | RARRAY_AREF has been a macro for reasons. We might not be able to change that for public APIs, but why not relax the situation internally to make it an inline function.
* Fix links to Dig Methods document (#3421)Burdette Lamar2020-08-141-1/+1
| | | | | * Fix links to Dig Methods document * Fix links to Dig Methods document
* Adding doc/dig_methods.rdoc and links to it (#3416)Burdette Lamar2020-08-131-11/+12
| | | | | | | Adds a full discussion of #dig, along with links from Array, Hash, Struct, and OpenStruct. CSV::Table and CSV::Row are over in ruby/csv. I'll get to them soon. The art to the thing is to figure out how much (or how little) to say at each #dig.
* MAYBE_UNUSED should just suffice卜部昌平2020-08-131-5/+2
| | | | This reverts commit c355fa72d4e356378a8b03a67432b52bafcc308b.
* Enhanced RDoc for Array (#3400)Burdette Lamar2020-08-101-28/+180
| | | | | | | | | | | Methods: drop drop_while any? all? none? one?
* Removed non-ASCII code to suppress warnings by localized compilersNobuyoshi Nakada2020-08-101-2/+2
|
* Suppress unused-function warningsNobuyoshi Nakada2020-08-101-0/+5
| | | | Calls with a constant argument should be optimized away.
* Enhanced RDoc for Array#take and Array#take_while (#3398)Burdette Lamar2020-08-071-19/+38
|
* Enhanced RDoc for Array#product (#3395)Burdette Lamar2020-08-071-13/+55
|
* Enhanced documentation for Array#repeated_combination (#3392)Burdette Lamar2020-08-051-25/+62
| | | | | * Enhanced documentation for Array#repeated_combination * Enhanced documentation for Array#repeated_combination
* Enhanced documentation for Array#repeated_permutation (#3390)Burdette Lamar2020-08-051-14/+63
| | | | | * Enhanced documentation for Array#repeated_permutation * Enhanced documentation for Array#repeated_permutation
* Initialize memo pointer and use it consistently to silence gcc 7+Nobuyoshi Nakada2020-08-011-5/+5
|
* Enhanced RDoc for ArrayBurdette Lamar2020-07-311-44/+159
|
* Document Array#flatten{,!} accept explicit nil argument [ci skip]Jeremy Evans2020-07-301-4/+4
| | | | Fixes [Bug #10475]
* Fix Array#flatten for recursive array when given positive depth [Bug #17092]Marc-Andre Lafortune2020-07-301-18/+26
|
* Enhanced RDoc for Array (#3372)Burdette Lamar2020-07-291-80/+142
|
* Enhanced RDoc for Array [ci skip]BurdetteLamar2020-07-281-96/+240
|
* Use https instead of httpKazuhiro NISHIYAMA2020-07-281-1/+1
|
* Enhanced RDoc for Array (#3350)Burdette Lamar2020-07-221-46/+72
| | | | | | | | | | | | * Enhanced RDoc for Array Methods: == eql? hash include? <=>
* Enhanced RDoc for ArrayBurdetteLamar2020-07-211-7/+1
|
* Enhanced RDoc for ArrayBurdetteLamar2020-07-211-2/+4
|
* Enhanced RDoc for ArrayBurdetteLamar2020-07-211-60/+90
|
* Optimize Array#min (#3324)Kenta Murata2020-07-181-7/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The benchmark result is below: | |compare-ruby|built-ruby| |:---------------|-----------:|---------:| |ary2.min | 39.105M| 39.442M| | | -| 1.01x| |ary10.min | 23.995M| 30.762M| | | -| 1.28x| |ary100.min | 6.249M| 10.783M| | | -| 1.73x| |ary500.min | 1.408M| 2.714M| | | -| 1.93x| |ary1000.min | 828.397k| 1.465M| | | -| 1.77x| |ary2000.min | 332.256k| 570.504k| | | -| 1.72x| |ary3000.min | 338.079k| 573.868k| | | -| 1.70x| |ary5000.min | 168.217k| 286.114k| | | -| 1.70x| |ary10000.min | 85.512k| 143.551k| | | -| 1.68x| |ary20000.min | 43.264k| 71.935k| | | -| 1.66x| |ary50000.min | 17.317k| 29.107k| | | -| 1.68x| |ary100000.min | 9.072k| 14.540k| | | -| 1.60x| |ary1000000.min | 872.930| 1.436k| | | -| 1.64x| compare-ruby is 9f4b7fc82e.
* Optimize Array#max (#3325)Kenta Murata2020-07-181-7/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The benchmark result is below: | |compare-ruby|built-ruby| |:---------------|-----------:|---------:| |ary2.max | 38.837M| 40.830M| | | -| 1.05x| |ary10.max | 23.035M| 32.626M| | | -| 1.42x| |ary100.max | 5.490M| 11.020M| | | -| 2.01x| |ary500.max | 1.324M| 2.679M| | | -| 2.02x| |ary1000.max | 699.167k| 1.403M| | | -| 2.01x| |ary2000.max | 284.321k| 570.446k| | | -| 2.01x| |ary3000.max | 282.613k| 571.683k| | | -| 2.02x| |ary5000.max | 145.120k| 285.546k| | | -| 1.97x| |ary10000.max | 72.102k| 142.831k| | | -| 1.98x| |ary20000.max | 36.065k| 72.077k| | | -| 2.00x| |ary50000.max | 14.343k| 29.139k| | | -| 2.03x| |ary100000.max | 7.586k| 14.472k| | | -| 1.91x| |ary1000000.max | 726.915| 1.495k| | | -| 2.06x|
* Enhanced RDoc for Array#fill (#3301)Burdette Lamar2020-07-111-20/+208
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Enhanced RDoc for Array#fill * Update array.c There's one more at 5072. I'll get it. Co-authored-by: Eric Hodel <drbrain@segment7.net> * Update array.c Co-authored-by: Eric Hodel <drbrain@segment7.net> * Update array.c Co-authored-by: Eric Hodel <drbrain@segment7.net> * Update array.c Co-authored-by: Eric Hodel <drbrain@segment7.net> * Update array.c Co-authored-by: Eric Hodel <drbrain@segment7.net> * Update array.c Co-authored-by: Eric Hodel <drbrain@segment7.net>
* Enhanced RDoc for Array (#3282)Burdette Lamar2020-07-081-59/+140
| | | | | | | | | | | | Methods: reject! reject delete_if zip transpose replace clear
* Enhanced RDoc for Array (#3276)Burdette Lamar2020-07-031-51/+191
| | | | | | | | | *Methods: keep_if delete delete_at slice!
* rb_ary_slice_bang: do not goto into a branch卜部昌平2020-06-291-22/+38
| | | | | I'm not necessarily against every goto in general, but jumping into a branch is definitely a bad idea. Better refactor.
* ary_join_1: do not goto into a branch卜部昌平2020-06-291-35/+38
| | | | | I'm not necessarily against every goto in general, but jumping into a branch is definitely a bad idea. Better refactor.
* rb_ary_aset: do not goto into a branch卜部昌平2020-06-291-14/+22
| | | | | I'm not necessarily against every goto in general, but jumping into a branch is definitely a bad idea. Better refactor.
* add spaces [ci skip]卜部昌平2020-06-291-1/+8
|
* ary_ensure_room_for_unshift: do not goto into a branch卜部昌平2020-06-291-31/+44
| | | | | I'm not necessarily against every goto in general, but jumping into a branch is definitely a bad idea. Better refactor.
* rb_ary_behead: do not goto into a branch卜部昌平2020-06-291-21/+35
| | | | | I'm not necessarily against every goto in general, but jumping into a branch is definitely a bad idea. Better refactor.
* [ci skip] Enhanced RDoc for Array (#3252)Burdette Lamar2020-06-241-73/+132
| | | | | | | | | | Methods: map/collect map!/collect! values_at select/filter select!/filter!
* [ci skip] Enhanced RDoc for Array (#3237)Burdette Lamar2020-06-231-107/+272
| | | | | | | | | | | Methods: #rotate! #rotate #sort! #sort #bsearch #bsearch_index
* [ci skip] Enhanced RDoc for Array (#3224)Burdette Lamar2020-06-181-31/+52
| | | | | | | | | | Methods: #to_a #to_h #to_ary #reverse! #reverse
* Remove non-US-ASCII characters [ci skip]Nobuyoshi Nakada2020-06-141-2/+2
|
* [ci skip] Enhanced RDoc for Array (#3219)Burdette Lamar2020-06-131-19/+59
| | | | | | | | Methods: #join #inspect/#to_s #to_a
* [ci skip] Enhanced Rdoc for Array (#3216)Burdette Lamar2020-06-121-46/+160
| | | | | | | | | | | Methods: #insert #each #each_index #reverse_each #length #empty?
* Enhanced Rdoc for Array#rindex and Array#[]= (#3204)Burdette Lamar2020-06-111-57/+189
| | | | | * Enhanced Rdoc for Array#rindex and Array#[]= * Enhanced Rdoc for Array#rindex and Array#[]=
* Enhanced Rdoc for Array#fetch and Array#index (#3202)Burdette Lamar2020-06-101-40/+94
| | | | | * Enhanced Rdoc for Array#fetch and Array#index * Couple of tweaks (per review) in Rdoc for Hash
* Enhanced Rdoc for Array (#3193)Burdette Lamar2020-06-091-96/+294
| | | | | | | | | | | | | | | Methods: #freeze #<< #push #pop #shift #unshift #slice #at #first #last
* Fix max, min, minmax documentation (#3131)Masataka Pocke Kuwabara2020-05-261-2/+2
| | | | They only need that all objects implement <=>, but the documentation said it needs Comparable.
* Suppress warnings no inline ruby debug (#3107)Kenta Murata2020-05-221-1/+1
| | | | | * Suppress unused warnings occurred due to -fno-inline * Suppress warning occurred due to RUBY_DEBUG=1
* add static modifier to rb_ary_aref2 funcS-H-GAMELINKS2020-05-191-1/+1
|
* [ci skip] Rdoc enhancements for Array (#3063)Burdette Lamar2020-05-151-83/+191
| | | | | | | * Per @nobu review * Rdoc enhancements for Array * Responses to review
* reroute redefinition of NDEBUG卜部昌平2020-04-211-0/+1
| | | | | NDEBUG can be defined via a command-line argument. Should take care of such situations.
* Merge pull request #2991 from shyouhei/ruby.h卜部昌平2020-04-081-10/+11
| | | Split ruby.h
* Removed non-RUBY_INTEGER_UNIFICATION codeNobuyoshi Nakada2020-03-211-1/+1
|
* fix compile error w/ -DUSE_TRANSIENT_HEAP=0卜部昌平2020-03-041-0/+2
| | | | | rb_transient_heap_managed_ptr_p is available only when USE_TRANSIENT_HEAP. Need #if guards.