Crate code_span

source ·
Expand description

Code Span

Add additional information to your code spans.

fn main() {
    use code_span::CodeView;
    let mut view = CodeView::blank("public static class MyClass {}");
    view.mark_offset(0, 6, Some("keyword"));
    view.mark_offset(7, 13, Some("keyword"));
}

Structs

Each character of these code stores the same information
Save the given code and store additional information on each character
Arguments