File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -760,7 +760,7 @@ impl EmitterWriter {
760
760
annotations_position. push ( ( p, annotation) ) ;
761
761
for ( j, next) in annotations. iter ( ) . enumerate ( ) {
762
762
if j > i {
763
- let l = next. label . map_or ( 0 , |label| label. len ( ) + 2 ) ;
763
+ let l = next. label . as_ref ( ) . map_or ( 0 , |label| label. len ( ) + 2 ) ;
764
764
if ( overlaps ( next, annotation, l) // Do not allow two labels to be in the same
765
765
// line if they overlap including padding, to
766
766
// avoid situations like:
@@ -1655,7 +1655,7 @@ impl FileWithAnnotatedLines {
1655
1655
line_index : usize ,
1656
1656
ann : Annotation ) {
1657
1657
1658
- for slot in file_vec {
1658
+ for slot in file_vec. iter_mut ( ) {
1659
1659
// Look through each of our files for the one we're adding to
1660
1660
if slot. file . name == file. name {
1661
1661
// See if we already have a line for it
You can’t perform that action at this time.
0 commit comments