string.c (rb_str_dump): Fix the rdoc

* Officially states that String#dump is intended for round-trip.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66894 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
mame 2019-01-21 08:51:51 +00:00
parent 8a294e0f20
commit 6891a1cd5d

View File

@ -6002,7 +6002,10 @@ rb_str_inspect(VALUE str)
* str.dump -> new_str
*
* Produces a version of +str+ with all non-printing characters replaced by
* <code>\nnn</code> notation and all special characters escaped.
* <code>\xnn</code> notation and all special characters escaped.
*
* This API is intended for round-trip: if the result string is eval'ed,
* it produces the original string.
*
* "hello \n ''".dump #=> "\"hello \\n ''\""
*/