rust/library/std/src
AngelicosPhosphoros 4b62a77e4d Little improves in CString new when creating from slice
Old code already contain optimization for cases with `&str` and `&[u8]` args. This commit adds a specialization for `&mut[u8]` too.

Also, I added usage of old slice in search for zero bytes instead of new buffer because it produce better code for Windows on LTO builds. For other platforms, this wouldn't cause any difference because it calls `libc` anyway.

Inlined `_new` method into spec trait to reduce amount of code generated to `CString::new` callers.
2021-12-27 12:26:30 +03:00
..
backtrace Add Frames iterator for Backtrace 2021-01-23 11:56:33 -06:00
collections Auto merge of #91761 - matthiaskrgr:rollup-bjowmvz, r=matthiaskrgr 2021-12-11 03:52:12 +00:00
env std: move "mod tests/benches" to separate files 2020-08-31 02:56:59 +00:00
error std: move "mod tests/benches" to separate files 2020-08-31 02:56:59 +00:00
f32 Implement IEEE 754-2019 minimun and maximum functions for f32/f64 2021-11-20 10:14:03 +01:00
f64 Remove fNN::lerp - consensus unlikely 2021-10-25 22:44:41 -05:00
ffi Little improves in CString new when creating from slice 2021-12-27 12:26:30 +03:00
fs Update stdlib to the 2021 edition 2021-12-18 00:21:53 +11:00
io Rollup merge of #91947 - ibraheemdev:io-error-other, r=joshtriplett 2021-12-16 17:23:10 +01:00
lazy Upgrade wasm32 image to Ubuntu 20.04 2021-02-06 13:05:56 +01:00
net Fix a bunch of typos 2021-12-14 16:40:43 +01:00
num rustc_expand: Mark inner #![test] attributes as soft-unstable 2020-11-20 19:35:03 +03:00
os Revert "socket ancillary data implementation for dragonflybsd." 2021-12-16 21:32:53 +00:00
panic review: fix nits and move panic safety tests to the correct place 2020-09-25 23:10:24 +02:00
path add benchmarks and tests for Hash and Eq impls on Path 2021-11-09 20:54:00 +01:00
prelude Stabilize asm! and global_asm! 2021-12-12 11:20:03 +00:00
process fix test in std::process on android 2021-11-23 13:57:22 +08:00
sync Add #[must_use] to remaining std functions (O-Z) 2021-10-30 23:37:32 -04:00
sys Revert "socket ancillary data implementation for dragonflybsd." 2021-12-16 21:32:53 +00:00
sys_common Fix a bunch of typos 2021-12-14 16:40:43 +01:00
thread Update stdlib to the 2021 edition 2021-12-18 00:21:53 +11:00
time Add #[must_use] to remaining std functions (O-Z) 2021-10-30 23:37:32 -04:00
alloc.rs Rename rterr to rtprintpanic 2021-05-19 15:52:09 +02:00
ascii.rs Convert many files to intra-doc links 2020-09-02 17:37:40 -04:00
backtrace.rs Add #[must_use] to remaining std functions (A-N) 2021-10-30 23:44:02 -04:00
env.rs Rollup merge of #89999 - talagrand:GetTempPath2, r=m-ou-se 2021-12-09 05:08:31 +01:00
error.rs Stabilize try_reserve 2021-10-04 10:29:46 +01:00
f32.rs Remove fNN::lerp - consensus unlikely 2021-10-25 22:44:41 -05:00
f64.rs Remove fNN::lerp - consensus unlikely 2021-10-25 22:44:41 -05:00
fs.rs Correct since attribute for feature 2021-12-11 13:47:20 +03:00
keyword_docs.rs Simplify for loop desugar 2021-11-21 08:15:21 -06:00
lazy.rs Add #[must_use] to core and std constructors 2021-10-10 02:44:26 -04:00
lib.rs Rollup merge of #91881 - Patrick-Poitras:stabilize-iter-zip, r=scottmcm 2021-12-15 01:28:08 +01:00
macros.rs bump bootstrap compiler to 1.55 2021-08-01 11:19:24 -04:00
num.rs Add Saturating type (based on Wrapping type) 2021-08-10 19:27:01 +02:00
panic.rs Deduplicate panic_fmt 2021-10-19 15:02:21 +01:00
panicking.rs Fix a bunch of typos 2021-12-14 16:40:43 +01:00
path.rs Correct since attribute for feature 2021-12-11 13:47:20 +03:00
primitive_docs.rs Update docs. 2021-12-04 19:40:33 +01:00
process.rs Update stdlib to the 2021 edition 2021-12-18 00:21:53 +11:00
rt.rs Rollup merge of #89068 - bjorn3:restructure_rt2, r=joshtriplett 2021-10-31 13:20:04 +01:00
time.rs Fix a bunch of typos 2021-12-14 16:40:43 +01:00