From 4a119365c416d991ee3185e39514d809d3775a8c Mon Sep 17 00:00:00 2001 From: Guillaume Gomez Date: Sun, 28 Jan 2024 11:42:32 +0100 Subject: [PATCH 1/2] Update pulldown-cmark version to 0.9.5 --- Cargo.lock | 6 +++--- compiler/rustc_resolve/Cargo.toml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 09eb0d98efc90..2b9c577e8b489 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3005,11 +3005,11 @@ dependencies = [ [[package]] name = "pulldown-cmark" -version = "0.9.3" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a1a2f1f0a7ecff9c31abbe177637be0e97a0aef46cf8738ece09327985d998" +checksum = "80eb9f69aec5cd8828765a75f739383fbbe3e8b9d84370bde1cc90487700794a" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.1", "memchr", "unicase", ] diff --git a/compiler/rustc_resolve/Cargo.toml b/compiler/rustc_resolve/Cargo.toml index a1a353ce0574e..77f35fcf89338 100644 --- a/compiler/rustc_resolve/Cargo.toml +++ b/compiler/rustc_resolve/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" [dependencies] # tidy-alphabetical-start bitflags = "2.4.1" -pulldown-cmark = { version = "0.9.3", default-features = false } +pulldown-cmark = { version = "0.9.5", default-features = false } rustc_arena = { path = "../rustc_arena" } rustc_ast = { path = "../rustc_ast" } rustc_ast_pretty = { path = "../rustc_ast_pretty" } From dad6802c86ad4df1b07fa0f4b6d6a08e6712b8e9 Mon Sep 17 00:00:00 2001 From: Guillaume Gomez Date: Sun, 28 Jan 2024 11:42:50 +0100 Subject: [PATCH 2/2] Add regression test for #100638 --- ...otnote-definition-without-blank-line-100638.rs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 tests/rustdoc/footnote-definition-without-blank-line-100638.rs diff --git a/tests/rustdoc/footnote-definition-without-blank-line-100638.rs b/tests/rustdoc/footnote-definition-without-blank-line-100638.rs new file mode 100644 index 0000000000000..b6f62c3bcba57 --- /dev/null +++ b/tests/rustdoc/footnote-definition-without-blank-line-100638.rs @@ -0,0 +1,15 @@ +#![crate_name = "foo"] + +//! Reference to footnotes A[^1], B[^2] and C[^3]. +//! +//! [^1]: Footnote A. +//! [^2]: Footnote B. +//! [^3]: Footnote C. + +// @has 'foo/index.html' +// @has - '//*[@class="docblock"]/*[@class="footnotes"]/ol/li[@id="fn1"]/p' 'Footnote A' +// @has - '//li[@id="fn1"]/p/a/@href' '#fnref1' +// @has - '//*[@class="docblock"]/*[@class="footnotes"]/ol/li[@id="fn2"]/p' 'Footnote B' +// @has - '//li[@id="fn2"]/p/a/@href' '#fnref2' +// @has - '//*[@class="docblock"]/*[@class="footnotes"]/ol/li[@id="fn3"]/p' 'Footnote C' +// @has - '//li[@id="fn3"]/p/a/@href' '#fnref3'