rdoc
rdoc copied to clipboard
Add :deprecated: and :since: directives
On ruby-core, a suggestion was made to add version information to all function documentation. I think that making it easier to do in a standardized way would be good. In my comment, I suggested a couple of directives:
:deprecated since::since:
I believe that :deprecated: is a better choice than :deprecated since:.
This isn’t entirely necessary, but it would make adopting this to be generated in a standard place for both web generated code and RI.
This would be used as:
# This function...
# Use #bar instead.
#
# :deprecated: 2.6
def foo(flag)
# ...
end
# This function...
#
# :since: 3.0
def bar(enable: false)
# ...
end
@halostatue Thanks to file this idea. I'm +1 to this feature.