chore(promql): let an evaluated chunk be cloned

`EvaluatedChunk` holds a `Series` and a bool, both cheap to copy behind their
existing ownership, so deriving `Clone` costs nothing. A consumer that has to keep
the chunk it matched on, or hand the same chunk to two stages, would otherwise
have to destructure and rebuild it.

Needed by the native tree, whose bound nodes receive chunks by value and reuse
them.

Signed-off-by: discord9 <discord9@users.noreply.github.com>
Signed-off-by: discord9 <55937128+discord9@users.noreply.github.com>
This commit is contained in:
discord9
2026-10-19 15:43:02 +08:00
parent 167d605edb
commit cd378b541f
+1 -1
View File
@@ -33,7 +33,7 @@ use datatypes::series::time::{GridRange, TimeAxis};
/// A series closes exactly once, on the chunk that carries `is_last`. A closed prefix is always
/// followed by a closing chunk, even when that chunk holds no values, so a consumer can tell
/// "nothing more here" from "no more input".
#[derive(Debug)]
#[derive(Clone, Debug)]
pub struct EvaluatedChunk {
/// The evaluated values, addressed on their absolute grid positions.
pub series: Series,