[][src]Trait syntex_syntax2::diagnostics::plugin::CodeMapper

pub trait CodeMapper {
    fn lookup_char_pos(&self, pos: BytePos) -> Loc;
fn span_to_lines(&self, sp: Span) -> Result<FileLines, SpanLinesError>;
fn span_to_string(&self, sp: Span) -> String;
fn span_to_filename(&self, sp: Span) -> String;
fn merge_spans(&self, sp_lhs: Span, sp_rhs: Span) -> Option<Span>; }

Required methods

fn lookup_char_pos(&self, pos: BytePos) -> Loc

fn span_to_lines(&self, sp: Span) -> Result<FileLines, SpanLinesError>

fn span_to_string(&self, sp: Span) -> String

fn span_to_filename(&self, sp: Span) -> String

fn merge_spans(&self, sp_lhs: Span, sp_rhs: Span) -> Option<Span>

Loading content...

Implementors

impl CodeMapper for CodeMap[src]

Loading content...