]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/complex_types.rs
Auto merge of #6304 - matthiaskrgr:crash_6302, r=llogiq
[rust.git] / tests / ui / complex_types.rs
index eac2c07c12ea9a4d7fb56bb756f137a50a910ea7..be61fb6b9be613cca8bd66f622644b253af6cabd 100644 (file)
@@ -1,7 +1,5 @@
-#![feature(tool_lints)]
-
 #![warn(clippy::all)]
-#![allow(unused, clippy::needless_pass_by_value)]
+#![allow(unused, clippy::needless_pass_by_value, clippy::vec_box)]
 #![feature(associated_type_defaults)]
 
 type Alias = Vec<Vec<Box<(u32, u32, u32, u32)>>>; // no warning here
@@ -22,19 +20,21 @@ enum E {
 
 impl S {
     const A: (u32, (u32, (u32, (u32, u32)))) = (0, (0, (0, (0, 0))));
-    fn impl_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) { }
+    fn impl_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
 }
 
 trait T {
     const A: Vec<Vec<Box<(u32, u32, u32, u32)>>>;
     type B = Vec<Vec<Box<(u32, u32, u32, u32)>>>;
     fn method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>);
-    fn def_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) { }
+    fn def_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
 }
 
-fn test1() -> Vec<Vec<Box<(u32, u32, u32, u32)>>> { vec![] }
+fn test1() -> Vec<Vec<Box<(u32, u32, u32, u32)>>> {
+    vec![]
+}
 
-fn test2(_x: Vec<Vec<Box<(u32, u32, u32, u32)>>>) { }
+fn test2(_x: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
 
 fn test3() {
     let _y: Vec<Vec<Box<(u32, u32, u32, u32)>>> = vec![];
@@ -57,5 +57,4 @@ struct D {
     ),
 }
 
-fn main() {
-}
+fn main() {}