[DOC] Tweaks for Array#reverse!

This commit is contained in:
BurdetteLamar 2024-10-09 11:33:22 -05:00 committed by Peter Zhu
parent 377d022853
commit 1962be267c
Notes: git 2024-10-09 18:02:55 +00:00

11
array.c
View File

@ -3123,13 +3123,16 @@ rb_ary_reverse(VALUE ary)
/*
* call-seq:
* array.reverse! -> self
* reverse! -> self
*
* Reverses +self+ in place:
* Reverses the order of the elements of +self+;
* returns +self+:
*
* a = ['foo', 'bar', 'two']
* a.reverse! # => ["two", "bar", "foo"]
* a = [0, 1, 2]
* a.reverse! # => [2, 1, 0]
* a # => [2, 1, 0]
*
* Related: see {Methods for Assigning}[rdoc-ref:Array@Methods+for+Assigning].
*/
static VALUE