public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Miguel Ojeda <ojeda@kernel.org>
To: Miguel Ojeda <ojeda@kernel.org>,
	Wedson Almeida Filho <wedsonaf@gmail.com>,
	Alex Gaynor <alex.gaynor@gmail.com>
Cc: "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>,
	"Josh Stone" <jistone@redhat.com>,
	"William Brown" <william.brown@suse.com>,
	"Georgy Yakovlev" <gyakovlev@gentoo.org>,
	"Jan Alexander Steffens" <jan.steffens@gmail.com>,
	rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org,
	patches@lists.linux.dev
Subject: [PATCH 2/3] rust: arc: fix intra-doc link in `Arc<T>::init`
Date: Tue, 18 Apr 2023 23:43:46 +0200	[thread overview]
Message-ID: <20230418214347.324156-3-ojeda@kernel.org> (raw)
In-Reply-To: <20230418214347.324156-1-ojeda@kernel.org>

`Arc<T>::init` refers to `Arc<T>::pin_init` via an intra-doc link
using the text `pin_init`, rather than more explicitly, which makes
`rustdoc` point it to the `pin_init!` macro instead.

This is required for the compiler upgrade since the newer `rustdoc`
would trigger the `broken_intra_doc_links` lint [1], but in this case
the macro was not the intended target to begin with, and so the actual
fix is to make it point to the right place, regardless of the upgrade.

Thus make it more explicit.

Fixes: 92c4a1e7e81c ("rust: init/sync: add `InPlaceInit` trait to pin-initialize smart pointers")
Link: https://github.com/rust-lang/rust/issues/106142 [1]
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
---
 rust/kernel/sync/arc.rs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rust/kernel/sync/arc.rs b/rust/kernel/sync/arc.rs
index e6d206242465..1b0734fdf6a7 100644
--- a/rust/kernel/sync/arc.rs
+++ b/rust/kernel/sync/arc.rs
@@ -185,7 +185,7 @@ impl<T> Arc<T> {
 
     /// Use the given initializer to in-place initialize a `T`.
     ///
-    /// This is equivalent to [`pin_init`], since an [`Arc`] is always pinned.
+    /// This is equivalent to [`Arc<T>::pin_init`], since an [`Arc`] is always pinned.
     #[inline]
     pub fn init<E>(init: impl Init<T, E>) -> error::Result<Self>
     where
-- 
2.40.0


  parent reply	other threads:[~2023-04-18 21:44 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-18 21:43 [PATCH 0/3] Rust 1.68.2 upgrade Miguel Ojeda
2023-04-18 21:43 ` [PATCH 1/3] rust: alloc: clarify what is the upstream version Miguel Ojeda
2023-04-19  2:51   ` Martin Rodriguez Reboredo
2023-04-19  8:06   ` Benno Lossin
2023-04-19 11:58   ` Gary Guo
2023-04-20 12:14   ` Björn Roy Baron
2023-04-18 21:43 ` Miguel Ojeda [this message]
2023-04-19  2:51   ` [PATCH 2/3] rust: arc: fix intra-doc link in `Arc<T>::init` Martin Rodriguez Reboredo
2023-04-19  8:11   ` Benno Lossin
2023-04-19 11:59   ` Gary Guo
2023-04-20 12:15   ` Björn Roy Baron
2023-04-18 21:43 ` [PATCH 3/3] rust: upgrade to Rust 1.68.2 Miguel Ojeda
2023-04-19  3:02   ` Martin Rodriguez Reboredo
2023-05-31 17:02     ` Miguel Ojeda
     [not found]       ` <22ac8a99-d243-c537-41c7-ff2c5e69d28f@gmail.com>
2023-05-31 21:30         ` Miguel Ojeda
2023-04-19 12:38   ` Gary Guo
2023-04-20 12:31   ` Björn Roy Baron
2023-04-18 22:17 ` [PATCH 0/3] Rust 1.68.2 upgrade Miguel Ojeda
2023-04-20  3:23 ` Boqun Feng
2023-04-20  3:45 ` David Gow
2023-04-20 13:12 ` Ariel Miculas
2023-04-20 13:19   ` Miguel Ojeda
2023-04-20 17:17     ` Ariel Miculas
2023-04-20 17:20       ` Miguel Ojeda
2023-05-04 22:27         ` Fabien Parent
2023-05-05  9:59           ` Miguel Ojeda
2023-05-31 17:03 ` 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=20230418214347.324156-3-ojeda@kernel.org \
    --to=ojeda@kernel.org \
    --cc=alex.gaynor@gmail.com \
    --cc=benno.lossin@proton.me \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=gary@garyguo.net \
    --cc=gyakovlev@gentoo.org \
    --cc=jan.steffens@gmail.com \
    --cc=jistone@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=patches@lists.linux.dev \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=wedsonaf@gmail.com \
    --cc=william.brown@suse.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