about summary refs log tree commit diff
path: root/src/liballoc/alloc
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2019-12-01 06:00:33 +0000
committerbors <bors@rust-lang.org>2019-12-01 06:00:33 +0000
commit4007d4ef26eab44bdabc2b7574d032152264d3ad (patch)
treefeada823fc5b16040da2f7aba36cda434f0b2fa4 /src/liballoc/alloc
parent135ccbaca86ed4b9c0efaf0cd31442eae57ffad7 (diff)
parentbed4c09d21aceb440ee61091b68dd653da32b45b (diff)
downloadrust-4007d4ef26eab44bdabc2b7574d032152264d3ad.tar.gz
rust-4007d4ef26eab44bdabc2b7574d032152264d3ad.zip
Auto merge of #66917 - Centril:rollup-xj2enik, r=Centril
Rollup of 9 pull requests

Successful merges:

 - #66503 (More useful test error messages on should_panic(expected=...) mismatch)
 - #66662 (Miri: run panic-catching tests in liballoc)
 - #66679 (Improve lifetime errors with implicit trait object lifetimes)
 - #66726 (Use recursion_limit for const eval stack limit)
 - #66790 (Do `min_const_fn` checks for `SetDiscriminant`s target)
 - #66832 (const_prop: detect and avoid catching Miri errors that require allocation)
 - #66880 (Add long error code explanation message for E0203)
 - #66890 (Format liballoc with rustfmt)
 - #66896 (pass Queries to compiler callbacks)

Failed merges:

r? @ghost
Diffstat (limited to 'src/liballoc/alloc')
-rw-r--r--src/liballoc/alloc/tests.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/liballoc/alloc/tests.rs b/src/liballoc/alloc/tests.rs
index c69f4e49ee1..956298d7836 100644
--- a/src/liballoc/alloc/tests.rs
+++ b/src/liballoc/alloc/tests.rs
@@ -1,15 +1,15 @@
 use super::*;
 
 extern crate test;
-use test::Bencher;
 use crate::boxed::Box;
+use test::Bencher;
 
 #[test]
 fn allocate_zeroed() {
     unsafe {
         let layout = Layout::from_size_align(1024, 1).unwrap();
-        let ptr = Global.alloc_zeroed(layout.clone())
-            .unwrap_or_else(|_| handle_alloc_error(layout));
+        let ptr =
+            Global.alloc_zeroed(layout.clone()).unwrap_or_else(|_| handle_alloc_error(layout));
 
         let mut i = ptr.cast::<u8>().as_ptr();
         let end = i.add(layout.size());