Skip to main content

take_warnings

Function take_warnings 

Source
pub fn take_warnings() -> Vec<Warning>
Expand description

Drain the warning sinks without building anything.

The sinks are global and are only emptied by a successful build, so a load that fails partway leaves whatever it managed to warn about sitting there, ready to be misattributed to the next file. Anything checking more than one document in a row needs to be able to clear them between files.