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

ruby-changes:63522

From: Marc-Andre <ko1@a...>
Date: Thu, 5 Nov 2020 07:52:25 +0900 (JST)
Subject: [ruby-changes:63522] 015b023820 (master): [ruby/ostruct] Restore `ostruct` doc

https://git.ruby-lang.org/ruby.git/commit/?id=015b023820

From 015b0238204616d4c0612459ef91411fa79a9eb5 Mon Sep 17 00:00:00 2001
From: Marc-Andre Lafortune <github@m...>
Date: Wed, 4 Nov 2020 16:09:51 -0500
Subject: [ruby/ostruct] Restore `ostruct` doc


diff --git a/lib/ostruct.rb b/lib/ostruct.rb
index 823c829..45ccb54 100644
--- a/lib/ostruct.rb
+++ b/lib/ostruct.rb
@@ -36,15 +36,15 @@ https://github.com/ruby/ruby/blob/trunk/lib/ostruct.rb#L36
 # Hash keys with spaces or characters that could normally not be used for
 # method calls (e.g. <code>()[]*</code>) will not be immediately available
 # on the OpenStruct object as a method for retrieval or assignment, but can
-# still be reached through the Object#__send__ method or using [].
+# still be reached through the Object#send method or using [].
 #
 #   measurements = OpenStruct.new("length (in inches)" => 24)
 #   measurements[:"length (in inches)"]       # => 24
-#   measurements.__send__("length (in inches)")   # => 24
+#   measurements.send("length (in inches)")   # => 24
 #
 #   message = OpenStruct.new(:queued? => true)
 #   message.queued?                           # => true
-#   message.__send__("queued?=", false)
+#   message.send("queued?=", false)
 #   message.queued?                           # => false
 #
 # Removing the presence of an attribute requires the execution of the
-- 
cgit v0.10.2


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

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