summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--hash.c12
-rw-r--r--struct.c6
-rw-r--r--version.h2
3 files changed, 10 insertions, 10 deletions
diff --git a/hash.c b/hash.c
index 7c844da965..c90814b2ee 100644
--- a/hash.c
+++ b/hash.c
@@ -2874,19 +2874,19 @@ rb_hash_any_p(VALUE hash)
* call-seq:
* hsh.dig(key, ...) -> object
*
- * Extracts the nested value specified by the sequence of <i>idx</i>
+ * Extracts the nested value specified by the sequence of <i>key</i>
* objects by calling +dig+ at each step, returning +nil+ if any
* intermediate step is +nil+.
*
* h = { foo: {bar: {baz: 1}}}
*
- * h.dig(:foo, :bar, :baz) #=> 1
- * h.dig(:foo, :zot, :xyz) #=> nil
+ * h.dig(:foo, :bar, :baz) #=> 1
+ * h.dig(:foo, :zot, :xyz) #=> nil
*
* g = { foo: [10, 11, 12] }
- * g.dig(:foo, 1) #=> 11
- * g.dig(:foo, 1, 0) #=> TypeError: Integer does not have #dig method
- * g.dig(:foo, :bar) #=> TypeError: no implicit conversion of Symbol into Integer
+ * g.dig(:foo, 1) #=> 11
+ * g.dig(:foo, 1, 0) #=> TypeError: Integer does not have #dig method
+ * g.dig(:foo, :bar) #=> TypeError: no implicit conversion of Symbol into Integer
*/
VALUE
diff --git a/struct.c b/struct.c
index 6303436122..9289338a16 100644
--- a/struct.c
+++ b/struct.c
@@ -1136,15 +1136,15 @@ rb_struct_ptr(VALUE s)
* call-seq:
* struct.dig(key, ...) -> object
*
- * Extracts the nested value specified by the sequence of <i>idx</i>
+ * Extracts the nested value specified by the sequence of +key+
* objects by calling +dig+ at each step, returning +nil+ if any
* intermediate step is +nil+.
*
* klass = Struct.new(:a)
* o = klass.new(klass.new({b: [1, 2, 3]}))
*
- * o.dig(:a, :a, :b, 0) #=> 1
- * o.dig(:b, 0) #=> nil
+ * o.dig(:a, :a, :b, 0) #=> 1
+ * o.dig(:b, 0) #=> nil
*/
static VALUE
diff --git a/version.h b/version.h
index 88a4e8669f..a4e8f09301 100644
--- a/version.h
+++ b/version.h
@@ -1,6 +1,6 @@
#define RUBY_VERSION "2.4.0"
#define RUBY_RELEASE_DATE "2017-03-13"
-#define RUBY_PATCHLEVEL 71
+#define RUBY_PATCHLEVEL 72
#define RUBY_RELEASE_YEAR 2017
#define RUBY_RELEASE_MONTH 3