diff --git a/lib/rdoc/text.rb b/lib/rdoc/text.rb index 6f1a2b8d15..7c97c61ffd 100644 --- a/lib/rdoc/text.rb +++ b/lib/rdoc/text.rb @@ -313,6 +313,6 @@ module RDoc::Text # Character class to be separated by a space when concatenating # lines. - SPACE_SEPARATED_LETTER_CLASS = /[\p{Nd}\p{Lc}\p{Pc}]/ + SPACE_SEPARATED_LETTER_CLASS = /[\p{Nd}\p{Lc}\p{Pc}]|[!-~&&\W]/ end diff --git a/test/rdoc/test_rdoc_markup_to_html.rb b/test/rdoc/test_rdoc_markup_to_html.rb index 2dd8cf922d..e3affa533c 100644 --- a/test/rdoc/test_rdoc_markup_to_html.rb +++ b/test/rdoc/test_rdoc_markup_to_html.rb @@ -257,7 +257,7 @@ class TestRDocMarkupToHtml < RDoc::Markup::FormatterTestCase end def accept_paragraph_break - assert_equal "\n
hello
world
hello
world
#{ohayo}#{sekai}
\n", @to.res.join + + @to.start_accepting + @to.accept_paragraph para("+hello+\n", "world\n") + assert_equal "\nhello
world
hello world
hello
world