pub fn refresh_problems_view(
activator: &mut dyn ModeActivator,
view_id: BufferId,
entries: &[ErrorEntry],
) -> Option<usize>Expand description
RV.3 (2026-08-10): rebuild an existing *problems* view from the
current error list, in place. Returns the new entry count, or None
when the view is unknown to the multibuffer registry or the fresh
entry set yields nothing to show (in which case the view is left
exactly as it was — a refresh must never blank the buffer the user
is reading).
In place is the whole point: create_problems_view mints a new
BufferId every call, so “refresh” cannot be a re-open without
stranding the old view and opening a second *problems*.
crate::MultibufferDocumentHandle::replace_excerpts swaps the
source map and excerpt list atomically and republishes, so the
buffer the user is looking at simply becomes current.
Sources are re-read from disk, which is the point of a refresh here: the view’s sources are freshly-spawned handles taken at open time, not the live editor buffers, so both the error list and the file contents may have moved on.