clippy_utils::source

Function snippet_opt

source
pub fn snippet_opt(sess: &impl HasSession, span: Span) -> Option<String>
Expand description

Converts a span to a code snippet. Returns None if not available.