1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Add alias treatment to method_documentation.rdoc (#3468)

* Add alias treatment to method_documentation.rdoc
This commit is contained in:
Burdette Lamar 2020-08-28 13:39:16 -05:00 committed by GitHub
parent 3ffef9a032
commit 4a5dd970a7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
Notes: git 2020-08-29 03:39:47 +09:00
Merged-By: BurdetteLamar <BurdetteLamar@Yahoo.com>

View file

@ -23,6 +23,7 @@ The general structure of the method documentation should be:
* Details and Examples
* Argument Description (if necessary)
* Corner Cases and Exceptions
* Aliases
* Related Methods (optional)
== call-seq (for methods written in C)
@ -62,6 +63,8 @@ Instead of:
However, as shown above for <tt>Array#count</tt>, use separate lines if the
behavior is different if the argument is omitted.
Omit aliases from the call-seq.
== Synopsis
The synopsis comes next, and is a short description of what the
@ -131,6 +134,10 @@ you do not need to document that a TypeError is raised if a non-integer
is passed. Do not provide examples of exceptions being raised unless
that is a common case, such as Hash#fetch raising KeyError.
== Aliases
Mention aliases in the form "Array#find_index is an alias for Array#index."
== Related Methods (optional)
In some cases, it is useful to document which methods are related to