Skip to main content

window_instants_fit

Function window_instants_fit 

Source
fn window_instants_fit(op: &BoundWindow) -> bool
Expand description

Whether the runtime can compute the timestamps op reads.

Unlike the window itself, which a point of the grid opens alone, these timestamps are sums of the window’s own parts: an @ anchor becomes an offset from the grid’s first point, and predict_linear adds that offset to the first and last point of the grid. Every term of either sum is bound on the node, but a sum of two that fit can still leave i64, and the runtime refuses the window when one does. Asking fold_offset and predict_linear_instants here rather than repeating their arithmetic keeps the two verdicts the same one: a query whose only refusal is this one keeps the plan it had instead of failing while the runtime is built.