Skip to main content

replace_current_source

Function replace_current_source 

Source
pub fn replace_current_source(source: Option<&str>) -> SourceContextGuard
Expand description

Replace the current source text for this thread.

This is used for UX features like “show the original expression” in legends and for diagnostics that need to slice the source by byte-span.