ruby-changes:72113
From: Alexander <ko1@a...>
Date: Fri, 10 Jun 2022 03:40:42 +0900 (JST)
Subject: [ruby-changes:72113] adcfd69690 (master): [DOC] Fix markup for `String` (#5984)
https://git.ruby-lang.org/ruby.git/commit/?id=adcfd69690 From adcfd6969070c3c51b35221d183728bbde8b8539 Mon Sep 17 00:00:00 2001 From: Alexander Ilyin <alexander.ilyin11@g...> Date: Thu, 9 Jun 2022 21:40:21 +0300 Subject: [DOC] Fix markup for `String` (#5984) * Add missing space for `String#start_with?`. * Add missing pluses for `String#tr` and `Methods for Converting to New String` label. * Move quote into the tag for `Whitespace in Strings` label. --- doc/string/start_with_p.rdoc | 2 +- string.c | 2 +- string.rb | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/string/start_with_p.rdoc b/doc/string/start_with_p.rdoc index 1cfed76296..5d1f9f9543 100644 --- a/doc/string/start_with_p.rdoc +++ b/doc/string/start_with_p.rdoc @@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/doc/string/start_with_p.rdoc#L1 Returns whether +self+ starts with any of the given +string_or_regexp+. -Matches patterns against the beginning of+self+. +Matches patterns against the beginning of +self+. For each given +string_or_regexp+, the pattern is: - +string_or_regexp+ itself, if it is a Regexp. diff --git a/string.c b/string.c index 83d90ff3a9..84af905deb 100644 --- a/string.c +++ b/string.c @@ -7998,7 +7998,7 @@ rb_str_tr_bang(VALUE str, VALUE src, VALUE repl) https://github.com/ruby/ruby/blob/trunk/string.c#L7998 * * - Each occurrence of the first character specified by +selector+ * is translated to the first character in +replacements+. - * - Each occurrence of the second character specified by selector+ + * - Each occurrence of the second character specified by +selector+ * is translated to the second character in +replacements+. * - And so on. * diff --git a/string.rb b/string.rb index 22641fba3e..b410e09395 100644 --- a/string.rb +++ b/string.rb @@ -143,7 +143,7 @@ https://github.com/ruby/ruby/blob/trunk/string.rb#L143 # consisting of any mixture of the following: # # - NL (null): <tt>"\x00"</tt>, <tt>"\u0000"</tt>. -# - HT (horizontal tab): <tt>"\x09"</tt>, "<tt>\t"</tt>. +# - HT (horizontal tab): <tt>"\x09"</tt>, <tt>"\t"</tt>. # - LF (line feed): <tt>"\x0a"</tt>, <tt>"\n"</tt>. # - VT (vertical tab): <tt>"\x0b"</tt>, <tt>"\v"</tt>. # - FF (form feed): <tt>"\x0c"</tt>, <tt>"\f"</tt>. @@ -452,9 +452,9 @@ https://github.com/ruby/ruby/blob/trunk/string.rb#L452 # # _Substitution_ # -# - #dump: Returns a copy of +self with all non-printing characters replaced by \xHH notation +# - #dump: Returns a copy of +self+ with all non-printing characters replaced by \xHH notation # and all special characters escaped. -# - #undump: Returns a copy of +self with all <tt>\xNN</tt> notation replace by <tt>\uNNNN</tt> notation +# - #undump: Returns a copy of +self+ with all <tt>\xNN</tt> notation replace by <tt>\uNNNN</tt> notation # and all escaped characters unescaped. # - #sub: Returns a copy of +self+ with the first substring matching a given pattern # replaced with a given replacement string;. -- cgit v1.2.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/