@@ -3352,43 +3352,12 @@ sort_2(const void *ap, const void *bp, void *dummy)
3352
3352
3353
3353
/*
3354
3354
* call-seq:
3355
- * array. sort! -> self
3356
- * array. sort! {|a, b| ... } -> self
3355
+ * sort! -> self
3356
+ * sort! {|a, b| ... } -> self
3357
3357
*
3358
- * Returns +self+ with its elements sorted in place.
3359
- *
3360
- * With no block, compares elements using operator <tt>#<=></tt>
3361
- * (see Comparable):
3362
- *
3363
- * a = 'abcde'.split('').shuffle
3364
- * a # => ["e", "b", "d", "a", "c"]
3365
- * a.sort!
3366
- * a # => ["a", "b", "c", "d", "e"]
3367
- *
3368
- * With a block, calls the block with each element pair;
3369
- * for each element pair +a+ and +b+, the block should return an integer:
3370
- *
3371
- * - Negative when +b+ is to follow +a+.
3372
- * - Zero when +a+ and +b+ are equivalent.
3373
- * - Positive when +a+ is to follow +b+.
3374
- *
3375
- * Example:
3376
- *
3377
- * a = 'abcde'.split('').shuffle
3378
- * a # => ["e", "b", "d", "a", "c"]
3379
- * a.sort! {|a, b| a <=> b }
3380
- * a # => ["a", "b", "c", "d", "e"]
3381
- * a.sort! {|a, b| b <=> a }
3382
- * a # => ["e", "d", "c", "b", "a"]
3383
- *
3384
- * When the block returns zero, the order for +a+ and +b+ is indeterminate,
3385
- * and may be unstable:
3386
- *
3387
- * a = 'abcde'.split('').shuffle
3388
- * a # => ["e", "b", "d", "a", "c"]
3389
- * a.sort! {|a, b| 0 }
3390
- * a # => ["d", "e", "c", "a", "b"]
3358
+ * Like Array#sort, but returns +self+ with its elements sorted in place.
3391
3359
*
3360
+ * Related: see {Methods for Assigning}[rdoc-ref:Array@Methods+for+Assigning].
3392
3361
*/
3393
3362
3394
3363
VALUE
0 commit comments