Skip to content

Commit

Permalink
Rollup merge of rust-lang#44450 - SergioBenitez:master, r=nrc
Browse files Browse the repository at this point in the history
Add `impl From<Vec<Span>> for MultiSpan`.

A simple `impl`.

r? @nrc
  • Loading branch information
frewsxcv authored Sep 15, 2017
2 parents 5255ab7 + 5d3626d commit 1e2d6a8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/libsyntax_pos/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,12 @@ impl From<Span> for MultiSpan {
}
}

impl From<Vec<Span>> for MultiSpan {
fn from(spans: Vec<Span>) -> MultiSpan {
MultiSpan::from_spans(spans)
}
}

pub const NO_EXPANSION: SyntaxContext = SyntaxContext::empty();

/// Identifies an offset of a multi-byte character in a FileMap
Expand Down

0 comments on commit 1e2d6a8

Please sign in to comment.