Re: [PATCH 08/12] rust: pin-init: rewrite the initializer macros using `syn`

From: Gary Guo

Date: Sat Jan 10 2026 - 14:20:13 EST


On Sat Jan 10, 2026 at 6:14 PM GMT, Benno Lossin wrote:
> On Fri Jan 9, 2026 at 2:45 PM CET, Gary Guo wrote:
>> On Thu Jan 8, 2026 at 1:50 PM GMT, Benno Lossin wrote:
>>> + quote! {
>>> + {
>>> + #value_prep
>>> + // SAFETY: TODO
>>> + unsafe { #write(::core::ptr::addr_of_mut!((*#slot).#ident), #value_ident) };
>>
>> This should be `&raw mut` now?
>
> Yes, but that involves adding workarounds for 1.81 and earlier. I'll
> leave it for a future series.

You can just enable `raw_ref_op` feature globally. We've already enabled it for
the kernel crate.

Best,
Gary