Use Vec<u8> for LOCAL_STD{OUT,ERR} instead of dyn Write.

It was only ever used with Vec<u8> anyway. This simplifies some things.

- It no longer needs to be flushed, because that's a no-op anyway for
  a Vec<u8>.

- Writing to a Vec<u8> never fails.

- No #[cfg(test)] code is needed anymore to use `realstd` instead of
  `std`, because Vec comes from alloc, not std (like Write).
This commit is contained in:
Mara Bos 2020-11-03 21:44:21 +01:00
parent ccbce1d3b2
commit f534b75f05
5 changed files with 28 additions and 78 deletions

View file

@ -297,6 +297,7 @@
#![feature(raw)]
#![feature(raw_ref_macros)]
#![feature(ready_macro)]
#![feature(refcell_take)]
#![feature(rustc_attrs)]
#![feature(rustc_private)]
#![feature(shrink_to)]