[PATCH] rust: kernel: list: fix incorrect pop_back example comment
From: Nikolai Grlica
Date: Mon Aug 10 2026 - 11:30:31 EST
The example uses pop_back(), but the accompanying comment says
pop_front(). Update the comment to match the example.
Signed-off-by: Nikolai Grlica <nikolai@xxxxxxxxxxxxxxxxx>
---
rust/kernel/list.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/kernel/list.rs b/rust/kernel/list.rs
index 406e3a028c55..0f367264ee2e 100644
--- a/rust/kernel/list.rs
+++ b/rust/kernel/list.rs
@@ -249,7 +249,7 @@
/// assert_eq!(list.iter().count(), 3);
/// }
///
-/// // Pop the items from the list using `pop_front()` and verify the content.
+/// // Pop the items from the list using `pop_back()` and verify the content.
/// {
/// assert_eq!(list.pop_back().ok_or(EINVAL)?.value.foo(), ("a", 15));
/// assert_eq!(list.pop_back().ok_or(EINVAL)?.value.foo(), ("a", 32));
--
2.55.0