From: Francis Laniel <laniel_francis@npnm.eu>
To: Alexandre Courbot <acourbot@nvidia.com>
Cc: "Miguel Ojeda" <ojeda@kernel.org>,
"Boqun Feng" <boqun@kernel.org>, "Gary Guo" <gary@garyguo.net>,
"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
"Benno Lossin" <lossin@kernel.org>,
"Andreas Hindborg" <a.hindborg@kernel.org>,
"Alice Ryhl" <aliceryhl@google.com>,
"Trevor Gross" <tmgross@umich.edu>,
"Danilo Krummrich" <dakr@kernel.org>,
"Daniel Almeida" <daniel.almeida@collabora.com>,
"Tamir Duberstein" <tamird@kernel.org>,
"Onur Özkan" <work@onurozkan.dev>,
"Thorsten Blum" <blum@kernel.org>,
rust-for-linux@vger.kernel.org
Subject: Re: [RFC PATCH v1 0/2] Add NonEmptySlice
Date: Mon, 12 Oct 2026 10:11:42 +0300 [thread overview]
Message-ID: <2854339.mvXUDI8C0e@pmachine> (raw)
In-Reply-To: <DM2FHZGKS6OA.W3GBZJFVVIVY@nvidia.com>
Hi,
Le lundi 12 octobre 2026, 03:21:21 heure d’été d’Europe de l’Est Alexandre Courbot a écrit :
> On Mon Oct 12, 2026 at 4:15 AM JST, Francis Laniel wrote:
> > Hi,
> >
> > Following the discussion in:
> > https://lore.kernel.org/rust-for-linux/DM0D9TERQAM3.2Y3HV6P68E2N8@garyguo.net/
> > I wrote some code to add a new NonEmptySlice type which ensures the underlying
> > type is no empty. This way, caller can use first()/last() without relying on
> > unsafe.
> >
> > For now, only new_mut() and last_mut() are used in uaccess.rs. Please let me
> > know if I need to remove the other functions from slice.rs to only what is
> > needed.
>
> Thanks for looking into this, but have you seen [1]? There is a Github
> issue opened with some comments [2] and you might want to coordinate
> with Lorenzo about who is going to work on this.
Sorry, I went faster than the music! Let me coordinate on GitHub with Lorenzo!
> I'll try to comment on the code later today.
>
> [1] https://lore.kernel.org/all/CANiq72=rwnogLqmpxnsvhsPWX+mBtH62=Yu_avQEYEmkWSVidQ@mail.gmail.com/
> [2] https://github.com/Rust-for-Linux/linux/issues/1262
>
Best regards,
prev parent reply other threads:[~2026-10-12 7:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-11 19:15 [RFC PATCH v1 0/2] Add NonEmptySlice Francis Laniel
2026-10-11 19:15 ` [RFC PATCH v1 1/2] rust: add NonEmptySlice Francis Laniel
2026-10-12 14:36 ` Alexandre Courbot
2026-10-12 15:11 ` Francis Laniel
2026-10-11 19:15 ` [RFC PATCH v1 2/2] rust: uaccess: Use slice::NonEmptySlice in strcpy_into_buf() Francis Laniel
2026-10-12 0:21 ` [RFC PATCH v1 0/2] Add NonEmptySlice Alexandre Courbot
2026-10-12 7:11 ` Francis Laniel [this message]
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=2854339.mvXUDI8C0e@pmachine \
--to=laniel_francis@npnm.eu \
--cc=a.hindborg@kernel.org \
--cc=acourbot@nvidia.com \
--cc=aliceryhl@google.com \
--cc=bjorn3_gh@protonmail.com \
--cc=blum@kernel.org \
--cc=boqun@kernel.org \
--cc=dakr@kernel.org \
--cc=daniel.almeida@collabora.com \
--cc=gary@garyguo.net \
--cc=lossin@kernel.org \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tamird@kernel.org \
--cc=tmgross@umich.edu \
--cc=work@onurozkan.dev \
/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