ruby-changes:64760
From: Marcus <ko1@a...>
Date: Tue, 5 Jan 2021 23:17:42 +0900 (JST)
Subject: [ruby-changes:64760] 3108ad7bf3 (master): [DOC] Fix grammar: "is same as" -> "is the same as"
https://git.ruby-lang.org/ruby.git/commit/?id=3108ad7bf3 From 3108ad7bf3dcae52054a1c29b86246cdb470000b Mon Sep 17 00:00:00 2001 From: Marcus Stollsteimer <sto.mar@w...> Date: Tue, 5 Jan 2021 15:13:53 +0100 Subject: [DOC] Fix grammar: "is same as" -> "is the same as" diff --git a/bignum.c b/bignum.c index 7c55366..192e384 100644 --- a/bignum.c +++ b/bignum.c @@ -75,7 +75,7 @@ STATIC_ASSERT(sizeof_long_and_sizeof_bdigit, SIZEOF_BDIGIT % SIZEOF_LONG == 0); https://github.com/ruby/ruby/blob/trunk/bignum.c#L75 #else # define HOST_BIGENDIAN_P 0 #endif -/* (!LSHIFTABLE(d, n) ? 0 : (n)) is same as n but suppress a warning, C4293, by Visual Studio. */ +/* (!LSHIFTABLE(d, n) ? 0 : (n)) is the same as n but suppress a warning, C4293, by Visual Studio. */ #define LSHIFTABLE(d, n) ((n) < sizeof(d) * CHAR_BIT) #define LSHIFTX(d, n) (!LSHIFTABLE(d, n) ? 0 : ((d) << (!LSHIFTABLE(d, n) ? 0 : (n)))) #define CLEAR_LOWBITS(d, numbits) ((d) & LSHIFTX(~((d)*0), (numbits))) diff --git a/cont.c b/cont.c index 524068b..cfd4eca 100644 --- a/cont.c +++ b/cont.c @@ -2226,7 +2226,7 @@ fiber_switch(rb_fiber_t *fiber, int argc, const VALUE *argv, int kw_splat, VALUE https://github.com/ruby/ruby/blob/trunk/cont.c#L2226 if (th->ec->fiber_ptr == fiber) { /* ignore fiber context switch - * because destination fiber is same as current fiber + * because destination fiber is the same as current fiber */ return make_passing_arg(argc, argv); } diff --git a/doc/NEWS-2.1.0 b/doc/NEWS-2.1.0 index 5d4152b..26f2374 100644 --- a/doc/NEWS-2.1.0 +++ b/doc/NEWS-2.1.0 @@ -155,7 +155,7 @@ with all sufficient information, see the ChangeLog file. https://github.com/ruby/ruby/blob/trunk/doc/NEWS-2.1.0#L155 Foo#foo private. * Kernel#untrusted?, untrust, and trust - * These methods are deprecated and their behavior is same as tainted?, + * These methods are deprecated and their behavior is the same as tainted?, taint, and untaint, respectively. If $VERBOSE is true, they show warnings. * Module#ancestors diff --git a/doc/NEWS-2.2.0 b/doc/NEWS-2.2.0 index 98e252e..8b2bd0b 100644 --- a/doc/NEWS-2.2.0 +++ b/doc/NEWS-2.2.0 @@ -318,7 +318,7 @@ with all sufficient information, see the ChangeLog file. https://github.com/ruby/ruby/blob/trunk/doc/NEWS-2.2.0#L318 * rb_sym2str() added. This is almost same as `rb_id2str(SYM2ID(sym))` but not pinning a dynamic symbol. -* rb_str_cat_cstr() added. This is same as `rb_str_cat2()`. +* rb_str_cat_cstr() added. This is the same as `rb_str_cat2()`. * `rb_str_substr()` and `rb_str_subseq()` will share middle of a string, but not only the end of a string, in the future. Therefore, result diff --git a/doc/extension.rdoc b/doc/extension.rdoc index 71a03cb..a499692 100644 --- a/doc/extension.rdoc +++ b/doc/extension.rdoc @@ -1868,13 +1868,13 @@ NORETURN_STYLE_NEW :: https://github.com/ruby/ruby/blob/trunk/doc/extension.rdoc#L1868 HAVE_RB_DEFINE_ALLOC_FUNC :: Means that function rb_define_alloc_func() is provided, that means the - allocation framework is used. This is same as the result of + allocation framework is used. This is the same as the result of have_func("rb_define_alloc_func", "ruby.h"). HAVE_RB_REG_NEW_STR :: Means that function rb_reg_new_str() is provided, that creates Regexp - object from String object. This is same as the result of + object from String object. This is the same as the result of have_func("rb_reg_new_str", "ruby.h"). HAVE_RB_IO_T :: diff --git a/doc/ractor.md b/doc/ractor.md index 235d584..8cfa9fe 100644 --- a/doc/ractor.md +++ b/doc/ractor.md @@ -192,7 +192,7 @@ For message sending and receiving, there are two types APIs: push type and pull https://github.com/ruby/ruby/blob/trunk/doc/ractor.md#L192 * (1-1) send/receive (push type) * `Ractor#send(obj)` (`Ractor#<<(obj)` is an aliases) send a message to the Ractor's incoming port. Incoming port is connected to the infinite size incoming queue so `Ractor#send` will never block. * `Ractor.receive` dequeue a message from its own incoming queue. If the incoming queue is empty, `Ractor.receive` calling will block. - * `Ractor.receive_if{|msg| filter_expr }` is variant of `Ractor.receive`. `receive_if` only receives a message which `filter_expr` is true (So `Ractor.receive` is same as `Ractor.receive_if{ true }`. + * `Ractor.receive_if{|msg| filter_expr }` is variant of `Ractor.receive`. `receive_if` only receives a message which `filter_expr` is true (So `Ractor.receive` is the same as `Ractor.receive_if{ true }`. * (1-2) yield/take (pull type) * `Ractor.yield(obj)` send an message to a Ractor which are calling `Ractor#take` via outgoing port . If no Ractors are waiting for it, the `Ractor.yield(obj)` will block. If multiple Ractors are waiting for `Ractor.yield(obj)`, only one Ractor can receive the message. * `Ractor#take` receives a message which is waiting by `Ractor.yield(obj)` method from the specified Ractor. If the Ractor does not call `Ractor.yield` yet, the `Ractor#take` call will block. diff --git a/eval.c b/eval.c index 55ac8b4..be6a6b4 100644 --- a/eval.c +++ b/eval.c @@ -1062,7 +1062,7 @@ rb_vrescue2(VALUE (* b_proc) (VALUE), VALUE data1, https://github.com/ruby/ruby/blob/trunk/eval.c#L1062 * * Equivalent to <code>begin .. rescue .. end</code>. * - * It is same as + * It is the same as * \code{cpp} * rb_rescue2(b_proc, data1, r_proc, data2, rb_eStandardError, (VALUE)0); * \endcode diff --git a/ext/pty/pty.c b/ext/pty/pty.c index e53871e..d927adc 100644 --- a/ext/pty/pty.c +++ b/ext/pty/pty.c @@ -271,7 +271,7 @@ get_device_once(int *master, int *slave, char SlaveName[DEVICELEN], int nomesg, https://github.com/ruby/ruby/blob/trunk/ext/pty/pty.c#L271 int flags = O_RDWR|O_NOCTTY; # if defined(O_CLOEXEC) /* glibc posix_openpt() in GNU/Linux calls open("/dev/ptmx", flags) internally. - * So version dependency on GNU/Linux is same as O_CLOEXEC with open(). + * So version dependency on GNU/Linux is the same as O_CLOEXEC with open(). * O_CLOEXEC is available since Linux 2.6.23. Linux 2.6.18 silently ignore it. */ flags |= O_CLOEXEC; # endif diff --git a/ext/socket/ipsocket.c b/ext/socket/ipsocket.c index 72fea78..b5cdc60 100644 --- a/ext/socket/ipsocket.c +++ b/ext/socket/ipsocket.c @@ -258,7 +258,7 @@ ip_inspect(VALUE sock) https://github.com/ruby/ruby/blob/trunk/ext/socket/ipsocket.c#L258 * If +reverse_lookup+ is +true+ or +:hostname+, * hostname is obtained from numeric_address using reverse lookup. * Or if it is +false+, or +:numeric+, - * hostname is same as numeric_address. + * hostname is the same as numeric_address. * Or if it is +nil+ or omitted, obeys to +ipsocket.do_not_reverse_lookup+. * See +Socket.getaddrinfo+ also. * @@ -299,7 +299,7 @@ ip_addr(int argc, VALUE *argv, VALUE sock) https://github.com/ruby/ruby/blob/trunk/ext/socket/ipsocket.c#L299 * If +reverse_lookup+ is +true+ or +:hostname+, * hostname is obtained from numeric_address using reverse lookup. * Or if it is +false+, or +:numeric+, - * hostname is same as numeric_address. + * hostname is the same as numeric_address. * Or if it is +nil+ or omitted, obeys to +ipsocket.do_not_reverse_lookup+. * See +Socket.getaddrinfo+ also. * @@ -341,7 +341,7 @@ ip_peeraddr(int argc, VALUE *argv, VALUE sock) https://github.com/ruby/ruby/blob/trunk/ext/socket/ipsocket.c#L341 * * _flags_ should be a bitwise OR of Socket::MSG_* constants. * - * ipaddr is same as IPSocket#{peeraddr,addr}. + * ipaddr is the same as IPSocket#{peeraddr,addr}. * * u1 = UDPSocket.new * u1.bind("127.0.0.1", 4913) diff --git a/ext/socket/socket.c b/ext/socket/socket.c index 3d8c650..5b6f4ab 100644 --- a/ext/socket/socket.c +++ b/ext/socket/socket.c @@ -1154,7 +1154,7 @@ sock_s_getservbyport(int argc, VALUE *argv, VALUE _) https://github.com/ruby/ruby/blob/trunk/ext/socket/socket.c#L1154 * be one of below. If _reverse_lookup_ is omitted, the default value is +nil+. * * +true+, +:hostname+: hostname is obtained from numeric address using reverse lookup, which may take a time. - * +false+, +:numeric+: hostname is same as numeric address. + * +false+, +:numeric+: hostname is the same as numeric address. * +nil+: obey to the current +do_not_reverse_lookup+ flag. * * If Addrinfo object is preferred, use Addrinfo.getaddrinfo. diff --git a/ext/win32/lib/win32/registry.rb b/ext/win32/lib/win32/registry.rb index ffc2979..b5b99ff 100644 --- a/ext/win32/lib/win32/registry.rb +++ b/ext/win32/lib/win32/registry.rb @@ -667,14 +667,14 @@ For detail, see the MSDN[http://msdn.microsoft.com/library/en-us/sysinfo/base/pr https://github.com/ruby/ruby/blob/trunk/ext/win32/lib/win32/registry.rb#L667 # # Read a registry value named name and return its value data. - # The class of value is same as #read method returns. + # The class of the value is the same as the #read method returns. # # If the value type is REG_EXPAND_SZ, returns value data whose environment # variables are replaced. # If the value type is neither REG_SZ, REG_MULTI_SZ, REG_DWORD, # REG_DWORD_BIG_ENDIAN, nor REG_QWORD, TypeError is raised. # - # The meaning of rtype is same as #read method. + # The meaning of rtype is the same as for the #read method. # def [](name, *rtype) type, data = read(name, *rtype) diff --git a/gc.c b/gc.c index ad2406c..c7220e5 100644 --- a/gc.c +++ b/gc.c @@ -3275,7 +3275,7 @@ incremental_enable(VALUE _) https://github.com/ruby/ruby/blob/trunk/gc.c#L3275 * This means that you can not walk through all Ruby object page * including freed object page. * - * Note: On this implementation, 'stride' is same as sizeof(RVALUE). + * Note: On this implementation, 'stride' is the same as sizeof(RVALUE). * However, there are possibilities to pass variable values with * 'stride' with some reasons. You must use stride instead of * use some constant value in the iteration. d (... truncated) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/