diff options
| author | The 8472 <git@infinite-source.de> | 2023-11-04 12:07:10 +0100 |
|---|---|---|
| committer | The 8472 <git@infinite-source.de> | 2023-11-04 16:11:01 +0100 |
| commit | 8d8f06b277a12e19189d6b08dbd9893db3283e9d (patch) | |
| tree | 9d958d01cedca3402c9b0554c939786397201f4c /compiler/rustc_parse/src/errors.rs | |
| parent | 9c20ddd956426d577d77cb3f57a7db2227a3c6e9 (diff) | |
| download | rust-8d8f06b277a12e19189d6b08dbd9893db3283e9d.tar.gz rust-8d8f06b277a12e19189d6b08dbd9893db3283e9d.zip | |
avoid excessive initialization when copying to a Vec
It now keeps track of initialized bytes to avoid reinitialization. It also keeps track of read sizes to avoid initializing more bytes than the reader needs. This is important when passing a huge vector to a Read that only has a few bytes to offer and doesn't implement read_buf().
Diffstat (limited to 'compiler/rustc_parse/src/errors.rs')
0 files changed, 0 insertions, 0 deletions
