Re: [PATCH] rust: sync: Accept errors for Lock payload data
From: Philipp Stanner
Date: Mon Sep 28 2026 - 04:15:52 EST
On Thu, 2026-09-24 at 11:41 +0100, Gary Guo wrote:
> On Thu Sep 24, 2026 at 9:55 AM BST, Philipp Stanner wrote:
> > The `Lock` baseclass currently does not allow for fallible user-data.
> > This can cause conflicts when used with other primitives, for example
> > when a lock shall be pin-initialized with payload data that is fallible.
> >
> > Add support for the lock base class so that it works with
> > try_pin_init!(). Adjust spinlock and mutex accordingly.
> >
> > Signed-off-by: Philipp Stanner <phasta@xxxxxxxxxx>
> > ---
> > Regarding removal of the CStrExt, I got "unused import" errors because
> > of it. Don't fully understand why?
>
> Because it's part of the prelude.
But why was it imported `as _` ?
P.