Skip to content

Commit c21058c

Browse files
ojeday86-dev
authored andcommitted
rust: enable rustdoc::unescaped_backticks lint
In Rust 1.71.0, `rustdoc` added the `unescaped_backticks` lint, which detects what are typically typos in Markdown formatting regarding inline code [1], e.g. from the Rust standard library: /// ... to `deref`/`deref_mut`` must ... /// ... use [`from_mut`]`. Specifically, ... It does not seem to have almost any false positives, from the experience of enabling it in the Rust standard library [2], which will be checked starting with Rust 1.82.0. The maintainers also confirmed it is ready to be used. Thus enable it. Link: https://doc.rust-lang.org/rustdoc/lints.html#unescaped_backticks [1] Link: rust-lang/rust#128307 [2] Reviewed-by: Trevor Gross <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Tested-by: Gary Guo <[email protected]> Reviewed-by: Gary Guo <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Miguel Ojeda <[email protected]> (cherry picked from commit bef83245f5ed434932aaf07f890142b576dc5d85) Signed-off-by: Paolo Bonzini <[email protected]>
1 parent 67c0a0c commit c21058c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,6 @@ prettyplease = { version = "0.2", features = ["verbatim"] }
3131

3232
[lints.rust]
3333
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(NO_UI_TESTS)', 'cfg(NO_ALLOC_FAIL_TESTS)'] }
34+
35+
[lints.rustdoc]
36+
unescaped_backticks = "deny"

0 commit comments

Comments
 (0)