Skip to content

Commit 6ed889a

Browse files
committed
Convert tick double quote in character entity references
1 parent 82eaefb commit 6ed889a

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

lib/rdoc/text.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ def to_html text
237237
when s.scan(/``/) then # backtick double quote
238238
html << encoded[:open_dquote]
239239
after_word = nil
240-
when s.scan(/''/) then # tick double quote
240+
when s.scan(/(?:&#39;|'){2}/) then # tick double quote
241241
html << encoded[:close_dquote]
242242
after_word = nil
243243
when s.scan(/`/) then # backtick

test/rdoc/test_rdoc_text.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -514,6 +514,7 @@ def test_to_html_dash
514514
def test_to_html_double_backtick
515515
assert_equal '“a', to_html('``a')
516516
assert_equal '“a“', to_html('``a``')
517+
assert_equal '“a”', to_html("``a''")
517518
end
518519

519520
def test_to_html_double_quote

0 commit comments

Comments
 (0)