mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/rdoc: Update to RDoc 3.7 (final)
* NEWS: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32264 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
41ab31e67a
commit
84ece95163
10 changed files with 201 additions and 111 deletions
|
@ -616,11 +616,16 @@ class RDoc::Markup
|
|||
end
|
||||
|
||||
##
|
||||
# We take +text+, parse it then invoke the output +formatter+ using a
|
||||
# Visitor to render the result.
|
||||
# We take +input+, parse it if necessary, then invoke the output +formatter+
|
||||
# using a Visitor to render the result.
|
||||
|
||||
def convert text, formatter
|
||||
document = RDoc::Markup::Parser.parse text
|
||||
def convert input, formatter
|
||||
document = case input
|
||||
when RDoc::Markup::Document then
|
||||
input
|
||||
else
|
||||
RDoc::Markup::Parser.parse input
|
||||
end
|
||||
|
||||
document.accept formatter
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue