Skip to content

Commit 54de274

Browse files
committed
Try fixing bigendian metadata serialisation
I compiled this on PPC to check and it seems to work, but not sure whether I didn't mess up anything in a major way. Maybe a good shot at #41443
1 parent 06fb4d2 commit 54de274

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustc_metadata/index.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ impl Index {
5858
let pos = buf.position();
5959

6060
// First we write the length of the lower range ...
61-
buf.write_all(words_to_bytes(&[self.positions[0].len() as u32])).unwrap();
61+
buf.write_all(words_to_bytes(&[(self.positions[0].len() as u32).to_le()])).unwrap();
6262
// ... then the values in the lower range ...
6363
buf.write_all(words_to_bytes(&self.positions[0][..])).unwrap();
6464
// ... then the values in the higher range.

0 commit comments

Comments
 (0)