summaryrefslogtreecommitdiff
path: root/array.c
diff options
context:
space:
mode:
authorkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-07-15 04:35:18 +0000
committerkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-07-15 04:35:18 +0000
commit40dad62c0528f09a1aa0a722422f355468a8b1e1 (patch)
tree9aa03c5a92d37f616c03cbc36001c01f88a876a6 /array.c
parent5d6c1f42d56e390732397bc115f7d7240eec5e10 (diff)
Fix warning: shadowing outer local variable - a
[ci skip][Fix GH-1628] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59338 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'array.c')
-rw-r--r--array.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/array.c b/array.c
index c700c93119..ecf1fed5c1 100644
--- a/array.c
+++ b/array.c
@@ -2455,9 +2455,9 @@ sort_2(const void *ap, const void *bp, void *dummy)
* The result is not guaranteed to be stable. When the comparison of two
* elements returns +0+, the order of the elements is unpredictable.
*
- * a = [ "d", "a", "e", "c", "b" ]
- * a.sort! #=> ["a", "b", "c", "d", "e"]
- * a.sort! { |a, b| b <=> a } #=> ["e", "d", "c", "b", "a"]
+ * ary = [ "d", "a", "e", "c", "b" ]
+ * ary.sort! #=> ["a", "b", "c", "d", "e"]
+ * ary.sort! { |a, b| b <=> a } #=> ["e", "d", "c", "b", "a"]
*
* See also Enumerable#sort_by.
*/
@@ -2539,9 +2539,9 @@ rb_ary_sort_bang(VALUE ary)
* The result is not guaranteed to be stable. When the comparison of two
* elements returns +0+, the order of the elements is unpredictable.
*
- * a = [ "d", "a", "e", "c", "b" ]
- * a.sort #=> ["a", "b", "c", "d", "e"]
- * a.sort { |a, b| b <=> a } #=> ["e", "d", "c", "b", "a"]
+ * ary = [ "d", "a", "e", "c", "b" ]
+ * ary.sort #=> ["a", "b", "c", "d", "e"]
+ * ary.sort { |a, b| b <=> a } #=> ["e", "d", "c", "b", "a"]
*
* See also Enumerable#sort_by.
*/