From a759f9f6156f720d6405a8245eba8b1d319d5a38 Mon Sep 17 00:00:00 2001 From: Simon Gardling Date: Tue, 18 Feb 2025 20:54:07 -0500 Subject: [PATCH] usage of TOP_K_CHILDREN --- src/future_moves.rs | 4 ++-- src/misc.rs | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/future_moves.rs b/src/future_moves.rs index f15b2a2..72bafe3 100644 --- a/src/future_moves.rs +++ b/src/future_moves.rs @@ -192,8 +192,8 @@ impl FutureMoves { if parent.lazy_children && !lazy_children { self.arena[parent_idx].lazy_children = false; // this move's children are being regenerated after lazy child expiration, don't append first node - if new.len() > 1 { - self.arena.extend(new.drain(1..)); + if new.len() > TOP_K_CHILDREN { + self.arena.extend(new.drain(TOP_K_CHILDREN..)); } else { // nothing will be appended // even though it was sorted the first time around diff --git a/src/misc.rs b/src/misc.rs index a9ca1bd..21e1033 100644 --- a/src/misc.rs +++ b/src/misc.rs @@ -28,7 +28,6 @@ where pub fn diag_raw( i_chains: [impl Iterator + Clone; 2], - j_chains: [impl Iterator + Clone; 2], ) -> [impl Iterator + Clone; 4] where