From: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
To: Andreas Hindborg <a.hindborg@kernel.org>
Cc: Oliver Mangold <oliver.mangold@pm.me>,
linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org
Subject: Re: [PATCH] Rust: Implement a unique reference type URef supplementing ARef
Date: Fri, 28 Feb 2025 14:17:37 +0100 [thread overview]
Message-ID: <CANiq72k_1tmXF+bTAeDfMYz=DOcEwsaS6v3d6NLjLPF-+7hwDA@mail.gmail.com> (raw)
In-Reply-To: <87wmdamiik.fsf@kernel.org>
On Fri, Feb 28, 2025 at 12:11 PM Andreas Hindborg <a.hindborg@kernel.org> wrote:
>
> When the trait is unsafe, we need to specify the conditions under which
> it is safe to implement:
>
> # Safety
>
> - Requirement 1
> - Requirement 2
> - etc
>
> See `AlwaysRefCounted` for reference on formatting.
I think should be caught by Clippy -- Oliver, please try building with
`CLIPPY=1` (we would like Clippy-clean builds as much as reasonably
possible), you should be getting something like:
error: docs for unsafe trait missing `# Safety` section
--> rust/........rs:23:1
|
23 | pub unsafe trait A {}
| ^^^^^^^^^^^^^^^^^^
|
= help: for further information visit
https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc
= note: `-D clippy::missing-safety-doc` implied by `-D warnings`
= help: to override `-D warnings` add
`#[allow(clippy::missing_safety_doc)]`
Thanks!
Cheers,
Miguel
next prev parent reply other threads:[~2025-02-28 13:17 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <jeyp4dToznpiAQYWHAABrEBIHVfxaIf7ntexop3d2AXQgnlytw3J8YFkX8E8EFKc1-USf_fVZqKhEmuNGE3O0w==@protonmail.internalid>
2025-02-21 8:04 ` [PATCH] Rust: Implement a unique reference type URef supplementing ARef Oliver Mangold
2025-02-21 8:12 ` Greg KH
2025-02-21 8:35 ` Oliver Mangold
2025-02-21 9:33 ` Andreas Hindborg
2025-02-28 11:10 ` Andreas Hindborg
2025-02-28 11:25 ` Andreas Hindborg
2025-02-28 11:31 ` Oliver Mangold
2025-02-28 12:16 ` Andreas Hindborg
2025-02-28 13:17 ` Miguel Ojeda [this message]
2025-03-04 6:19 ` kernel test robot
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='CANiq72k_1tmXF+bTAeDfMYz=DOcEwsaS6v3d6NLjLPF-+7hwDA@mail.gmail.com' \
--to=miguel.ojeda.sandonis@gmail.com \
--cc=a.hindborg@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=oliver.mangold@pm.me \
--cc=rust-for-linux@vger.kernel.org \
/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).