From 4f04d2dfca8aa566432843242535e964aaa1c358 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bennet=20Ble=C3=9Fmann?= Date: Thu, 31 Jul 2025 21:46:21 +0200 Subject: [PATCH] replace .skip(n).next() with .nth(n) --- src/machine/system_calls.rs | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/machine/system_calls.rs b/src/machine/system_calls.rs index 15a0d6a6..8c0eee0a 100644 --- a/src/machine/system_calls.rs +++ b/src/machine/system_calls.rs @@ -3793,11 +3793,7 @@ impl Machine { #[inline(always)] pub(crate) fn first_stream(&mut self) { - let first_stream = self - .indices - .iter_streams(..) - .filter(|s| !s.is_null_stream()) - .next(); + let first_stream = self.indices.iter_streams(..).find(|s| !s.is_null_stream()); if let Some(first_stream) = first_stream { let stream = first_stream.into(); @@ -3817,8 +3813,7 @@ impl Machine { .indices .iter_streams(prev_stream..) .filter(|s| !s.is_null_stream()) - .skip(1) - .next(); + .nth(1); if let Some(next_stream) = next_stream { let var = self.deref_register(2).as_var().unwrap(); -- 2.54.0