--- !ruby/object:RI::MethodDescription aliases: [] block_params: comment: - !ruby/struct:SM::Flow::P body: Returns a copy of str with the characters in from_str replaced by the corresponding characters in to_str. If to_str is shorter than from_str, it is padded with its last character. Both strings may use the c1--c2 notation to denote ranges of characters, and from_str may start with a ^, which denotes all characters except those listed. - !ruby/struct:SM::Flow::VERB body: " "hello".tr('aeiou', '*') #=> "h*ll*"\n "hello".tr('^aeiou', '*') #=> "e*o"\n "hello".tr('el', 'ip') #=> "hippo"\n "hello".tr('a-y', 'b-z') #=> "ifmmp"\n" full_name: String#tr is_singleton: false name: tr params: | str.tr(from_str, to_str) => new_str visibility: public