Skip to content

Commit 211feb1

Browse files
committed
Add {{produces}} tag to lint doc comments.
1 parent 321a598 commit 211feb1

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

compiler/rustc_lint/src/let_underscore.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ declare_lint! {
1111
/// scope.
1212
///
1313
/// ### Example
14-
/// ```rust
14+
/// ```
1515
/// struct SomeStruct;
1616
/// impl Drop for SomeStruct {
1717
/// fn drop(&mut self) {
@@ -20,6 +20,7 @@ declare_lint! {
2020
/// }
2121
///
2222
/// fn main() {
23+
/// #[warn(let_underscore_drop)]
2324
/// // SomeStuct is dropped immediately instead of at end of scope,
2425
/// // so "Dropping SomeStruct" is printed before "end of main".
2526
/// // The order of prints would be reversed if SomeStruct was bound to
@@ -28,6 +29,9 @@ declare_lint! {
2829
/// println!("end of main");
2930
/// }
3031
/// ```
32+
///
33+
/// {{produces}}
34+
///
3135
/// ### Explanation
3236
///
3337
/// Statements which assign an expression to an underscore causes the
@@ -66,6 +70,9 @@ declare_lint! {
6670
/// *lock += 1;
6771
/// });
6872
/// ```
73+
///
74+
/// {{produces}}
75+
///
6976
/// ### Explanation
7077
///
7178
/// Statements which assign an expression to an underscore causes the

0 commit comments

Comments
 (0)