pub fn poll_feed(
layer: &DiagnosticsLayer,
last_published: &mut usize,
enabled: bool,
) -> Option<Vec<ErrorEntry>>Expand description
Drive the live feed: rebuild whenever the layer’s revision moves and
the caller says the option is on, at most once per
COALESCE_INTERVAL.
Returns the revision it last published, so the caller can thread it
into the next tick. None means nothing was published this tick —
either the revision was unchanged or the feed is disabled.
Split out from any spawning so it is testable without a runtime: the coalescing rule is the part worth pinning, not tokio’s timer.