From: Yutaro Ohno <yutaro.ono.418@gmail.com>
To: "Miguel Ojeda" <ojeda@kernel.org>,
"Alex Gaynor" <alex.gaynor@gmail.com>,
"Wedson Almeida Filho" <wedsonaf@gmail.com>,
"Boqun Feng" <boqun.feng@gmail.com>,
"Gary Guo" <gary@garyguo.net>,
"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
"Benno Lossin" <benno.lossin@proton.me>,
"Andreas Hindborg" <a.hindborg@samsung.com>,
"Alice Ryhl" <aliceryhl@google.com>,
"Martin Rodriguez Reboredo" <yakoyoku@gmail.com>,
"Aswin Unnikrishnan" <aswinunni01@gmail.com>,
"FUJITA Tomonori" <fujita.tomonori@gmail.com>,
"Trevor Gross" <tmgross@umich.edu>
Cc: Yutaro Ohno <yutaro.ono.418@gmail.com>, rust-for-linux@vger.kernel.org
Subject: [PATCH] rust: macros: fix indentation in `module!`'s doc comment
Date: Tue, 13 Aug 2024 22:09:36 +0900 [thread overview]
Message-ID: <ZrtbEErNnBNNH0uF@ohnotp> (raw)
Clippy warns about list content in a doc comment that doesn't have extra
spaces at the beginning of a new line [1], like this:
```rust
/// * Do nothing.
/// * Then do something. Whatever it is needs done,
/// it should be done right now.
```
The suggested format is:
```rust
/// * Do nothing.
/// * Then do something. Whatever it is needs done,
/// it should be done right now.
```
This commit adds extra indentation to the `module!`'s doc comment to
suppress the warning.
Link: https://rust-lang.github.io/rust-clippy/master/index.html#/doc_lazy_continuation [1]
Signed-off-by: Yutaro Ohno <yutaro.ono.418@gmail.com>
---
rust/macros/lib.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/macros/lib.rs b/rust/macros/lib.rs
index 159e75292970..5be0cb9db3ee 100644
--- a/rust/macros/lib.rs
+++ b/rust/macros/lib.rs
@@ -94,7 +94,7 @@
/// - `license`: ASCII string literal of the license of the kernel module (required).
/// - `alias`: array of ASCII string literals of the alias names of the kernel module.
/// - `firmware`: array of ASCII string literals of the firmware files of
-/// the kernel module.
+/// the kernel module.
#[proc_macro]
pub fn module(ts: TokenStream) -> TokenStream {
module::module(ts)
--
2.46.0
next reply other threads:[~2024-08-13 13:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-13 13:09 Yutaro Ohno [this message]
2024-08-13 13:14 ` [PATCH] rust: macros: fix indentation in `module!`'s doc comment Miguel Ojeda
2024-08-13 13:22 ` Yutaro Ohno
2024-08-14 6:08 ` Additional patches for rust-fixes? (was: Re: [PATCH] rust: macros: fix indentation in `module!`'s doc comment) Dirk Behme
2024-08-14 10:46 ` Miguel Ojeda
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZrtbEErNnBNNH0uF@ohnotp \
--to=yutaro.ono.418@gmail.com \
--cc=a.hindborg@samsung.com \
--cc=alex.gaynor@gmail.com \
--cc=aliceryhl@google.com \
--cc=aswinunni01@gmail.com \
--cc=benno.lossin@proton.me \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun.feng@gmail.com \
--cc=fujita.tomonori@gmail.com \
--cc=gary@garyguo.net \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tmgross@umich.edu \
--cc=wedsonaf@gmail.com \
--cc=yakoyoku@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).