1 // Copyright 2014-2018 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution.
4 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
5 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
6 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
7 // option. This file may not be copied, modified, or distributed
8 // except according to those terms.
11 #![allow(unused, clippy::needless_pass_by_value)]
12 #![feature(associated_type_defaults)]
14 type Alias = Vec<Vec<Box<(u32, u32, u32, u32)>>>; // no warning here
16 const CST: (u32, (u32, (u32, (u32, u32)))) = (0, (0, (0, (0, 0))));
17 static ST: (u32, (u32, (u32, (u32, u32)))) = (0, (0, (0, (0, 0))));
20 f: Vec<Vec<Box<(u32, u32, u32, u32)>>>,
23 struct TS(Vec<Vec<Box<(u32, u32, u32, u32)>>>);
26 Tuple(Vec<Vec<Box<(u32, u32, u32, u32)>>>),
27 Struct { f: Vec<Vec<Box<(u32, u32, u32, u32)>>> },
31 const A: (u32, (u32, (u32, (u32, u32)))) = (0, (0, (0, (0, 0))));
32 fn impl_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
36 const A: Vec<Vec<Box<(u32, u32, u32, u32)>>>;
37 type B = Vec<Vec<Box<(u32, u32, u32, u32)>>>;
38 fn method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>);
39 fn def_method(&self, p: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
42 fn test1() -> Vec<Vec<Box<(u32, u32, u32, u32)>>> {
46 fn test2(_x: Vec<Vec<Box<(u32, u32, u32, u32)>>>) {}
49 let _y: Vec<Vec<Box<(u32, u32, u32, u32)>>> = vec![];
54 // should not warn, since we don't have control over the signature (#3222)