[DOC] Tweaks for String#gsub!

This commit is contained in:
BurdetteLamar 2025-08-03 09:13:44 -05:00 committed by Peter Zhu
parent 409da39afb
commit 72b8bb4caf

View file

@ -6576,15 +6576,12 @@ str_gsub(int argc, VALUE *argv, VALUE str, int bang)
* gsub!(pattern) {|match| ... } -> self or nil
* gsub!(pattern) -> an_enumerator
*
* Performs the specified substring replacement(s) on +self+;
* returns +self+ if any replacement occurred, +nil+ otherwise.
* Like String#gsub, except that:
*
* See {Substitution Methods}[rdoc-ref:String@Substitution+Methods].
*
* Returns an Enumerator if no +replacement+ and no block given.
*
* Related: String#sub, String#gsub, String#sub!.
* - Performs substitutions in +self+ (not in a copy of +self+).
* - Returns +self+ if any characters are removed, +nil+ otherwise.
*
* Related: see {Modifying}[rdoc-ref:String@Modifying].
*/
static VALUE