We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4bbe33c commit 474ad2eCopy full SHA for 474ad2e
src/rustdoc/markdown_pass.rs
@@ -420,6 +420,7 @@ fn write_nmod(ctxt: ctxt, doc: doc::nmoddoc) {
420
write_common(ctxt, doc.desc(), doc.sections());
421
422
for fndoc in doc.fns {
423
+ write_item_header(ctxt, doc::fntag(fndoc));
424
write_fn(ctxt, fndoc);
425
}
426
@@ -437,6 +438,12 @@ fn should_write_native_fns() {
437
438
assert str::contains(markdown, "test");
439
440
441
+#[test]
442
+fn should_write_native_fn_headers() {
443
+ let markdown = test::render("native mod a { #[doc = \"test\"] fn a(); }");
444
+ assert str::contains(markdown, "## Function `a`");
445
+}
446
+
447
fn write_fn(
448
ctxt: ctxt,
449
doc: doc::fndoc
0 commit comments