diff --git a/exercises/doubly-linked-list/example.rs b/exercises/doubly-linked-list/example.rs index a46dd40ea..7ad602634 100644 --- a/exercises/doubly-linked-list/example.rs +++ b/exercises/doubly-linked-list/example.rs @@ -139,6 +139,7 @@ impl Cursor<'_, T> { } } + #[allow(clippy::should_implement_trait)] pub fn next(&mut self) -> Option<&mut T> { // safe as node.next is a valid potential pointer unsafe { self._step(|node| node.next) } diff --git a/exercises/doubly-linked-list/src/lib.rs b/exercises/doubly-linked-list/src/lib.rs index 68a82afc5..2ecbc8bbf 100644 --- a/exercises/doubly-linked-list/src/lib.rs +++ b/exercises/doubly-linked-list/src/lib.rs @@ -44,6 +44,7 @@ impl Cursor<'_, T> { /// Move one position forward (towards the back) and /// return a reference to the new position + #[allow(clippy::should_implement_trait)] pub fn next(&mut self) -> Option<&mut T> { unimplemented!() }