@@ -50,12 +50,7 @@ pub struct Label<'a> {
5050
5151impl < ' a > Label < ' a > {
5252 pub fn new ( span : Span < u8 > , message : Cow < ' a , str > , style : Style ) -> Self {
53- Self {
54- span,
55- message,
56- style,
57- is_multiline_end : false ,
58- }
53+ Self { span, message, style, is_multiline_end : false }
5954 }
6055
6156 pub fn with_style ( self , style : Style ) -> Self {
@@ -229,11 +224,8 @@ impl Highlighter<'_> {
229224 ) ;
230225
231226 // indicate the portion of the line that the labels are pointing at
232- let LitLine {
233- line,
234- indicator_line,
235- messages,
236- } = LineHighlighter :: new ( self . source_code ) . highlight_line ( line_span, & line_labels) ;
227+ let LitLine { line, indicator_line, messages } =
228+ LineHighlighter :: new ( self . source_code ) . highlight_line ( line_span, & line_labels) ;
237229
238230 // 0. context-before
239231 // 1. line
@@ -630,7 +622,7 @@ mod test {
630622 use insta:: assert_snapshot;
631623 use owo_colors:: Style ;
632624
633- use super :: { render , sort_labels , Label } ;
625+ use super :: { Label , render , sort_labels } ;
634626
635627 fn span_of ( source : & str , word : & str ) -> Span < u8 > {
636628 let start = source. find ( word) . unwrap ( ) ;
0 commit comments