Skip to content

Commit 1843e1a

Browse files
committed
Fix rendering inside docblock short
1 parent 4157ff9 commit 1843e1a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/html/markdown.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,12 @@ pub fn render(w: &mut fmt::Formatter, md: &str, _: bool) -> fmt::Result {
160160
});
161161
try!(write!(w, "{}", out));
162162
}
163-
HmToken::EndTag{name: Cow::Borrowed("pre")} if rust_block => {
163+
HmToken::EndTag { name: Cow::Borrowed("pre") } if rust_block => {
164164
rust_block = false;
165165
}
166+
HmToken::EndTag { name: Cow::Borrowed("p") } => {
167+
try!(write!(w, "{}\n\n", hm_tok)); // hack to make render::shorter() work
168+
}
166169
_ => try!(write!(w, "{}", hm_tok)),
167170
}
168171
}

0 commit comments

Comments
 (0)