Messages in this thread Patch in this message |  | | From | Benno Lossin <> | | Subject | [PATCH 1/2] rust: pin-init: rename `project` -> `project_this` in doctest | | Date | Fri, 5 Sep 2025 19:12:06 +0200 |
| |
The next commit makes the `#[pin_data]` attribute generate a `project` function that would collide with any existing ones.
Link: https://github.com/Rust-for-Linux/pin-init/pull/75/commits/67fc90312149fd797078578612aac83b459a6ca4 Signed-off-by: Benno Lossin <lossin@kernel.org> --- rust/pin-init/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/pin-init/src/lib.rs b/rust/pin-init/src/lib.rs index 62e013a5cc20..2d0d9fd12524 100644 --- a/rust/pin-init/src/lib.rs +++ b/rust/pin-init/src/lib.rs @@ -994,7 +994,7 @@ macro_rules! try_init { /// } /// /// impl<T> Foo<T> { -/// fn project(self: Pin<&mut Self>) -> Pin<&mut T> { +/// fn project_this(self: Pin<&mut Self>) -> Pin<&mut T> { /// assert_pinned!(Foo<T>, elem, T, inline); /// /// // SAFETY: The field is structurally pinned. base-commit: 8f5ae30d69d7543eee0d70083daf4de8fe15d585 -- 2.50.1
|  |