Skip to main content

with_current_file

Function with_current_file 

Source
pub fn with_current_file<F, R>(filename: Option<String>, f: F) -> R
where F: FnOnce() -> R,
Expand description

Scope guard for setting the current filename — useful for native callers that want filename context in error messages without managing the thread-local manually.