Function rustc_middle::mir::spanview::write_next_viewable_with_overlaps
source · fn write_next_viewable_with_overlaps<'tcx, 'b, W>(
tcx: TyCtxt<'tcx>,
from_pos: BytePos,
to_pos: BytePos,
ordered_viewables: &'b [SpanViewable],
alt: bool,
layer: usize,
w: &mut W
) -> Result<(BytePos, &'b [SpanViewable])>where
W: Write,
Expand description
Recursively process each ordered span. Spans that overlap will have progressively varying
styles, such as increased padding for each overlap. Non-overlapping adjacent spans will
have alternating style choices, to help distinguish between them if, visually adjacent.
The layer
is incremented for each overlap, and the alt
bool alternates between true
and false, for each adjacent non-overlapping span. Source code between the spans (code
that is not in any coverage region) has neutral styling.