[前][次][番号順一覧][スレッド一覧]

ruby-changes:58543

From: Burdette <ko1@a...>
Date: Sat, 2 Nov 2019 15:33:08 +0900 (JST)
Subject: [ruby-changes:58543] 772b0613c5 (master): Correct documented return values for certain ENV methods (#2620)

https://git.ruby-lang.org/ruby.git/commit/?id=772b0613c5

From 772b0613c583773cd2eda23bce8275926a351e79 Mon Sep 17 00:00:00 2001
From: Burdette Lamar <BurdetteLamar@Y...>
Date: Sat, 2 Nov 2019 01:32:49 -0500
Subject: Correct documented return values for certain ENV methods (#2620)


diff --git a/hash.c b/hash.c
index da4738b..0eb101e 100644
--- a/hash.c
+++ b/hash.c
@@ -5194,7 +5194,7 @@ rb_env_size(VALUE ehash, VALUE args, VALUE eobj) https://github.com/ruby/ruby/blob/trunk/hash.c#L5194
 
 /*
  * call-seq:
- *   ENV.each_key { |name| block } -> Hash
+ *   ENV.each_key { |name| block } -> ENV
  *   ENV.each_key                  -> Enumerator
  *
  * Yields each environment variable name.
@@ -5249,7 +5249,7 @@ env_f_values(VALUE _) https://github.com/ruby/ruby/blob/trunk/hash.c#L5249
 
 /*
  * call-seq:
- *   ENV.each_value { |value| block } -> Hash
+ *   ENV.each_value { |value| block } -> ENV
  *   ENV.each_value                   -> Enumerator
  *
  * Yields each environment variable +value+.
@@ -5351,7 +5351,7 @@ env_reject_bang(VALUE ehash) https://github.com/ruby/ruby/blob/trunk/hash.c#L5351
 
 /*
  * call-seq:
- *   ENV.delete_if { |name, value| block } -> Hash
+ *   ENV.delete_if { |name, value| block } -> ENV
  *   ENV.delete_if                         -> Enumerator
  *
  * Deletes every environment variable for which the block evaluates to +true+.
@@ -5461,7 +5461,7 @@ env_select_bang(VALUE ehash) https://github.com/ruby/ruby/blob/trunk/hash.c#L5461
 
 /*
  * call-seq:
- *   ENV.keep_if { |name, value| block } -> Hash
+ *   ENV.keep_if { |name, value| block } -> ENV
  *   ENV.keep_if                         -> Enumerator
  *
  * Deletes every environment variable where the block evaluates to +false+.
@@ -5975,10 +5975,10 @@ env_update_i(VALUE key, VALUE val, VALUE _) https://github.com/ruby/ruby/blob/trunk/hash.c#L5975
 
 /*
  * call-seq:
- *   ENV.update(hash)                                        -> Hash
- *   ENV.update(hash) { |name, old_value, new_value| block } -> Hash
- *   ENV.merge!(hash)                                        -> Hash
- *   ENV.merge!(hash) { |name, old_value, new_value| block } -> Hash
+ *   ENV.update(hash)                                        -> ENV
+ *   ENV.update(hash) { |name, old_value, new_value| block } -> ENV
+ *   ENV.merge!(hash)                                        -> ENV
+ *   ENV.merge!(hash) { |name, old_value, new_value| block } -> ENV
  *
  * Adds the contents of +hash+ to the environment variables.  If no block is
  * specified entries with duplicate keys are overwritten, otherwise the value
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]