mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
doc: Add example for Symbol#to_s
* string.c: add example for Symbol#to_s. The docs for Symbol#to_s only include an example for Symbol#id2name, but not for #to_s which is an alias; the docs should include examples for both methods. From: Marcus Stollsteimer <sto.mar@web.de> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
559b51ff9c
commit
a6b9b360ce
1 changed files with 1 additions and 0 deletions
1
string.c
1
string.c
|
@ -9707,6 +9707,7 @@ sym_inspect(VALUE sym)
|
|||
* Returns the name or string corresponding to <i>sym</i>.
|
||||
*
|
||||
* :fred.id2name #=> "fred"
|
||||
* :ginger.to_s #=> "ginger"
|
||||
*/
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue