Re: [PATCH v4 6/6] rust: use strict provenance APIs

Benno Lossin
2025-03-17T15:00:35Z

On Mon Mar 17, 2025 at 3:13 PM CET, Tamir Duberstein wrote:
> On Mon, Mar 17, 2025 at 6:53 AM Tamir Duberstein <tamird@gmail.com> wrote:
>>
>> On Mon, Mar 17, 2025 at 5:34 AM Benno Lossin <benno.lossin@proton.me> wrote:
>> >
>> > > + pub fn expose_provenance<T>(addr: *const T) -> usize {
>> > > + addr.expose_provenance()
>> >
>> > Instead of having these stubs here, you can probably just do
>> >
>> > pub use core::ptr::expose_provenance;
>>
>> This doesn't work for the methods on primitives, but it works for the
>> free functions. Done.
>
> Have to revert this, writing `pub use ...` directly causes the MSRV
> clippy lint to fire at the caller.

Ah that is unfortunate.

---
Cheers,
Benno