[PATCH v4 3/7] rust: bitfield: fully qualify types in macro
From: Alexandre Courbot
Date: Wed May 27 2026 - 08:53:12 EST
These types were not fully qualified, which could cause issues if the
local module shadows them.
Signed-off-by: Alexandre Courbot <acourbot@xxxxxxxxxx>
---
rust/kernel/bitfield.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/rust/kernel/bitfield.rs b/rust/kernel/bitfield.rs
index b3ad5fdbfb23..2498107979dc 100644
--- a/rust/kernel/bitfield.rs
+++ b/rust/kernel/bitfield.rs
@@ -455,7 +455,7 @@ const fn [<__with_ $field>](
#[doc = "Returns the value of this field."]
#[inline(always)]
$vis fn $field(self) ->
- Result<
+ ::core::result::Result<
$try_into_type,
<$try_into_type as ::core::convert::TryFrom<
::kernel::num::Bounded<$storage, { $hi + 1 - $lo }>
@@ -508,7 +508,7 @@ const fn [<__with_ $field>](
self,
value: T,
) -> Self
- where T: Into<::kernel::num::Bounded<$storage, { $hi + 1 - $lo }>>,
+ where T: ::core::convert::Into<::kernel::num::Bounded<$storage, { $hi + 1 - $lo }>>,
{
self.[<__with_ $field>](value.into())
}
--
2.54.0