From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-40131.protonmail.ch (mail-40131.protonmail.ch [185.70.40.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E4B66183CD9; Wed, 12 Mar 2025 15:07:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.70.40.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741792030; cv=none; b=gl6TRJ2cZQ4c+DWBbQzflBqI+sORBbKr0RuAEUGdjm6t0Ap1IgutaruICCwE7T3w1HxfzS9QYz/E2wWc6rLAFlmqZsn+ICMemZEScMYU/0p4IKMa0FmIsVGrUDikEnbgoNnGj2BAHJMoGs+2VPCDXopATt0XJkVIBBv32ZZaE1U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741792030; c=relaxed/simple; bh=np+WIadGU74rpJjwWWZpkyFqUUgRYo8QS1bZY8rt66Y=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=LuKz37Ivq3KOrJ15trsuy/Z3L6ohAMDsf69N56VPBGvdCNlh8Fu+JeZbNuEDMTecTPgsPgWHZXe1nNpNk7a8J8+w74hfQZdvdcHJWyw8ZhvSYBL/Dc2om8GXbhFgcAp6o/g7yI9VEd0z3/4JEZFwtPBBLEfEp11FVeND1X9RTv0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=proton.me; spf=pass smtp.mailfrom=proton.me; dkim=pass (2048-bit key) header.d=proton.me header.i=@proton.me header.b=J3V/qstg; arc=none smtp.client-ip=185.70.40.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=proton.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=proton.me Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=proton.me header.i=@proton.me header.b="J3V/qstg" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proton.me; s=protonmail; t=1741792026; x=1742051226; bh=np+WIadGU74rpJjwWWZpkyFqUUgRYo8QS1bZY8rt66Y=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=J3V/qstg7dXBTPPUV/CHvZLEUogJaMJszagAnoFuQE5zGlpT5QzwGWMM3x5c/APr3 2RWeU1TZX97KgxfBJDkZJAWF+6rGaCnCAwY9C0CqNR9khJhgLkgKdo/fRxH2GewwJR qU1TpFaIcwEKrhaSyA7eVO4BpFFO57qmjX01UOwQ/tCPmV0a39W4YKbNGQAhDEU3Kt 8dPhFy9uX7hCWQS+Z7gLrHMU+9qd+uK3h+D3Z20EgmU2i9ObK5Ypr/p3/TSOfK4Aya oYxqYNIB15ZxH30nwvUROver467jBFhvsL9t+RmhhI2HCig0nxqlc6j8XpPRG3uh7Q mGD1khMVS20+A== Date: Wed, 12 Mar 2025 15:07:01 +0000 To: Tamir Duberstein , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Miguel Ojeda , Alex Gaynor , Boqun Feng , Gary Guo , =?utf-8?Q?Bj=C3=B6rn_Roy_Baron?= , Andreas Hindborg , Alice Ryhl , Trevor Gross , Danilo Krummrich , Greg Kroah-Hartman , "Rafael J. Wysocki" , Brendan Higgins , David Gow , Rae Moar , Bjorn Helgaas , Luis Chamberlain , Russ Weight , Rob Herring , Saravana Kannan From: Benno Lossin Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org, linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com, linux-pci@vger.kernel.org, linux-block@vger.kernel.org, devicetree@vger.kernel.org Subject: Re: [PATCH v2 0/5] rust: reduce pointer casts, enable related lints Message-ID: In-Reply-To: <20250309-ptr-as-ptr-v2-0-25d60ad922b7@gmail.com> References: <20250309-ptr-as-ptr-v2-0-25d60ad922b7@gmail.com> Feedback-ID: 71780778:user:proton X-Pm-Message-ID: c73bebe457e912f6fdcb06fff3fb73df91fb0eb0 Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Tamir, On Sun Mar 9, 2025 at 5:00 PM CET, Tamir Duberstein wrote: > This started with a patch that enabled `clippy::ptr_as_ptr`. Benno > Lossin suggested I also look into `clippy::ptr_cast_constness` and I > discovered `clippy::as_ptr_cast_mut`. This series now enables all 3 > lints. It also enables `clippy::as_underscore` which ensures other > pointer casts weren't missed. The first commit reduces the need for > pointer casts and is shared with another series[1]. > > Link: https://lore.kernel.org/all/20250307-no-offset-v1-0-0c728f63b69c@gm= ail.com/ [1] > > Signed-off-by: Tamir Duberstein Thanks for this series! Did you encounter any instances of `$val as $ty` where you couldn't convert them due to unsizing? I remember that we had some cases back then (maybe Alice remembers them too?). If not then no worries :) --- Cheers, Benno