mirror of
https://github.com/ruby/ruby.git
synced 2025-08-27 06:56:13 +02:00
![]() `--embed-mixins`
(https://github.com/ruby/rdoc/pull/842)
* Embed mixed-in methods and constants with `--embed-mixins`
When `--embed-mixins` option is set:
- methods from an `extend`ed module are documented as singleton methods
- attrs from an `extend`ed module are documented as class attributes
- methods from an `include`ed module are documented as instance methods
- attrs from an `include`ed module are documented as instance attributes
- constants from an `include`ed module are documented
Sections are created when needed, and Darkfish's template annotates
each of these mixed-in CodeObjects. We also respect the mixin methods'
visibility.
This feature is inspired by Yard's option of the same name.
* Add comment to document why we set object visibility
Co-authored-by: Stan Lo <stan001212@gmail.com>
* Add the mixin_from attribute to CodeObject's initializer
* Add test coverage for private mixed-in attributes.
---------
|
||
---|---|---|
.. | ||
code_object | ||
generator | ||
i18n | ||
markdown | ||
markup | ||
parser | ||
rd | ||
ri | ||
stats | ||
.document | ||
code_object.rb | ||
code_objects.rb | ||
comment.rb | ||
cross_reference.rb | ||
encoding.rb | ||
erb_partial.rb | ||
erbio.rb | ||
generator.rb | ||
i18n.rb | ||
known_classes.rb | ||
markdown.rb | ||
markup.rb | ||
options.rb | ||
parser.rb | ||
rd.rb | ||
rdoc.gemspec | ||
rdoc.rb | ||
ri.rb | ||
rubygems_hook.rb | ||
servlet.rb | ||
stats.rb | ||
store.rb | ||
task.rb | ||
text.rb | ||
token_stream.rb | ||
tom_doc.rb | ||
version.rb |