[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <D8S8AIAU4NQP.1IVXRJMF4I9AF@proton.me>
Date: Fri, 28 Mar 2025 21:48:12 +0000
From: Benno Lossin <benno.lossin@...ton.me>
To: Igor Korotin <igor.korotin@...oo.com>
Cc: linux-kernel@...r.kernel.org, rust-for-linux@...r.kernel.org
Subject: Re: [PATCH v2 0/1] rust: macros: Fix macro referencing core and kernel crates v2
This email seems to be a cover letter for the next version of your
patch. In that case, you should send it as its own thread to the list
(and not in reply to my previous email).
On Fri Mar 28, 2025 at 7:03 PM CET, Igor Korotin wrote:
>> > To prevent issues where user-defined modules named `core` or `kernel`
>> > could be picked up instead of the standard ones, update macros to use
>> > absolute paths, `::core::...` and `::kernel::...`, for core and kernel
>> > references.
>>
>> Please split this sentence up into smaller parts. Also "standard ones"
>> sounds weird to me, `core` and `kernel` are crates and not modules.
>
> Simplified the commit message.
You don't need to reply if you're fine with the suggestion :)
>> > Suggested-by: y86-dev <y86-dev@...tonmail.com>
>>
>> Please use my real name and other mail address instead:
>>
>> Benno Lossin <benno.lossin@...ton.me>
>
> Sure. Tried to find your creds via your github profile/commits without
> success.
>
>> > Closes: https://github.com/Rust-for-Linux/linux/issues/1150
>> > Signed-off-by: Igor Korotin <igor.korotin@...oo.com>
>> > ---
>> > rust/ffi.rs | 2 +-
>> > rust/kernel/device.rs | 2 +-
>> > rust/kernel/device_id.rs | 4 ++--
>> > rust/kernel/kunit.rs | 8 ++++----
>> > rust/kernel/static_assert.rs | 4 ++--
>> > rust/kernel/str.rs | 4 ++--
>> > rust/macros/lib.rs | 6 +++---
>> > scripts/rustdoc_test_gen.rs | 8 ++++++--
>> > 8 files changed, 21 insertions(+), 17 deletions(-)
>>
>> There are also some occurrences of `kernel::` & `core::` in proc macros,
>> for example:
>> - rust/macros/kunit.rs:129
>> - rust/macros/module.rs:347
>> - ...
>>
>> Could you also add those to the patch? Thanks!
>>
>> (line numbers after applying your patch to rust-next)
>
> Agreed. Fixed references in auto-generated code in files
> 1. rust/macros/kunit.rs
> 2. rust/macros/module.rs
> 3. scripts/rustdoc_test_builder.rs
> 4. scripts/rustdoc_test_gen.rs
Yeah those last two are also good finds.
---
Cheers,
Benno
Powered by blists - more mailing lists