rustdoc::clean::render_macro_matchers

Function snippet_equal_to_token

Source
fn snippet_equal_to_token(
    tcx: TyCtxt<'_>,
    matcher: &TokenTree,
) -> Option<String>
Expand description

Find the source snippet for this token’s Span, reparse it, and return the snippet if the reparsed TokenTree matches the argument TokenTree.