Commit 65d1e8d 1 parent 4a6d9de commit 65d1e8d Copy full SHA for 65d1e8d
File tree 1 file changed +11
-2
lines changed
src/tools/compiletest/src
1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -110,9 +110,18 @@ impl ProcOutput {
110
110
fn into_bytes ( self ) -> Vec < u8 > {
111
111
match self {
112
112
ProcOutput :: Full { bytes, .. } => bytes,
113
- ProcOutput :: Abbreviated { mut head, skipped, tail } => {
113
+ ProcOutput :: Abbreviated { mut head, mut skipped, tail } => {
114
+ let mut tail = & * tail;
115
+
116
+ // Skip over '{' at the start of the tail, so we don't later wrongfully consider this as json.
117
+ // See <https://rust-lang.zulipchat.com/#narrow/stream/182449-t-compiler.2Fhelp/topic/Weird.20CI.20failure/near/321797811>
118
+ while tail. get ( 0 ) == Some ( & b'{' ) {
119
+ tail = & tail[ 1 ..] ;
120
+ skipped += 1 ;
121
+ }
122
+
114
123
write ! ( & mut head, "\n \n <<<<<< SKIPPED {} BYTES >>>>>>\n \n " , skipped) . unwrap ( ) ;
115
- head. extend_from_slice ( & tail) ;
124
+ head. extend_from_slice ( tail) ;
116
125
head
117
126
}
118
127
}
You can’t perform that action at this time.
0 commit comments