diff --git a/ChangeLog b/ChangeLog index 16f648292f..54e5936a4e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Fri Aug 12 03:24:35 2011 Eric Hodel + + * backport r32935 from trunk + + * lib/rdoc: Import RDoc 3.9.2. Fixes TIDYLINK for HTML output. + Tue Aug 2 22:04:46 2011 NARUSE, Yui * backport r32815 from trunk. diff --git a/lib/rdoc.rb b/lib/rdoc.rb index 86c194f8ba..ddae96f53e 100644 --- a/lib/rdoc.rb +++ b/lib/rdoc.rb @@ -104,7 +104,7 @@ module RDoc ## # RDoc version you are using - VERSION = '3.9.1' + VERSION = '3.9.2' ## # Method visibilities diff --git a/lib/rdoc/markup/to_html.rb b/lib/rdoc/markup/to_html.rb index f87aabad6f..ca6522352d 100644 --- a/lib/rdoc/markup/to_html.rb +++ b/lib/rdoc/markup/to_html.rb @@ -74,7 +74,7 @@ class RDoc::Markup::ToHtml < RDoc::Markup::Formatter @markup.add_special(/((link:|https?:|mailto:|ftp:|www\.)\S+\w)/, :HYPERLINK) # and links of the form [] - @markup.add_special(/(((\{.*?\})|\b\S+?)\[\S+?\.\S+?\])/, :TIDYLINK) + @markup.add_special(/(((\{.*?\})|\b\S+?)\[\S+?\])/, :TIDYLINK) init_tags end diff --git a/test/rdoc/test_rdoc_markup_to_html_crossref.rb b/test/rdoc/test_rdoc_markup_to_html_crossref.rb index 2c566f0140..4f122512ac 100644 --- a/test/rdoc/test_rdoc_markup_to_html_crossref.rb +++ b/test/rdoc/test_rdoc_markup_to_html_crossref.rb @@ -25,6 +25,12 @@ class TestRDocMarkupToHtmlCrossref < XrefTestCase assert_equal "\n

C1

\n", result end + def test_convert_TIDYLINK_rdoc_ref + result = @to.convert '{foo}[rdoc-ref:C1]' + + assert_equal "\n

foo

\n", result + end + def test_gen_url assert_equal 'Some class', @to.gen_url('rdoc-ref:C1', 'Some class')