Re: [PATCH v2] rust: list: Add unsafe for container_of
From: Miguel Ojeda
Date: Tue Nov 18 2025 - 12:10:20 EST
On Tue, Nov 18, 2025 at 10:33 AM Philipp Stanner <phasta@xxxxxxxxxxx> wrote:
>
> It *is* absolutely common, or at least frequent, and you are the first
> guy in the entire project I ever heard complaining about it. Maybe it
> is often used wrongly or unnecessarily, though.
>
> But no worries, be assured that I will take this detail into account
> when working with you.
It is not, and since you seem to be keen on making an issue out of
this, I took a quick look.
What is actually common is using Cc: stable *without* constraints:
~84% of the cases in 2025.
And that is *before* removing the cases where the constraint is actually needed.
> So why then do you even suggest running rustfmt? How should I make it
> check the formatting?
I didn't suggest running `rustfmt`. I asked to please double-check if
that is the formatting that `rustfmt` *would* use, i.e. how those
blocks are normally formatted elsewhere, precisely because the tool
does not format it here.
Now, it isn't nice to try to frame things as if the issue is with the
other person (with remarks such as "first guy in the entire project"
and "when working with you").
So I will help you no further.
Cheers,
Miguel