ruby-changes:61280
From: Kazuhiro <ko1@a...>
Date: Sun, 17 May 2020 21:02:19 +0900 (JST)
Subject: [ruby-changes:61280] fa7addebb4 (master): Fix typos [ci skip]
https://git.ruby-lang.org/ruby.git/commit/?id=fa7addebb4 From fa7addebb498d92d059a020a1a9739e5522b27dc Mon Sep 17 00:00:00 2001 From: Kazuhiro NISHIYAMA <zn@m...> Date: Sun, 17 May 2020 21:01:29 +0900 Subject: Fix typos [ci skip] diff --git a/string.c b/string.c index fc4eb14..eac1d21 100644 --- a/string.c +++ b/string.c @@ -1579,7 +1579,7 @@ rb_str_resurrect(VALUE str) https://github.com/ruby/ruby/blob/trunk/string.c#L1579 * --- * * With no arguments, returns the empty string with the Encoding <tt>ASCII-8BIT</tt>: - * s = Str.new + * s = String.new * s # => "" * s.encoding # => #<Encoding:ASCII-8BIT> * @@ -1611,12 +1611,12 @@ rb_str_resurrect(VALUE str) https://github.com/ruby/ruby/blob/trunk/string.c#L1611 * With keyword +capacity+, returns a copy of +str+; * the given +capacity+ may set the size of the internal buffer, * which may affect performance: - * String.new(capacity: 1) # => " - * String.new(capacity: 4096) # => " + * String.new(capacity: 1) # => "" + * String.new(capacity: 4096) # => "" * * No exception is raised for zero or negative values: - * String.new(capacity: 0) # => " - * String.new(capacity: -1) # => " + * String.new(capacity: 0) # => "" + * String.new(capacity: -1) # => "" * * --- * -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/