]> git.lizzy.rs Git - rust.git/blob - src/test/ui/parser/missing-closing-angle-bracket-eq-constraint.rs
Auto merge of #100678 - GuillaumeGomez:improve-rustdoc-json-tests, r=aDotInTheVoid
[rust.git] / src / test / ui / parser / missing-closing-angle-bracket-eq-constraint.rs
1 struct Foo<T1, T2> {
2   _a : T1,
3   _b : T2,
4 }
5
6 fn test1<T>(arg : T) {
7   let v : Vec<(u32,_) = vec![];
8     //~^ ERROR: expected one of
9     //~| ERROR: type annotations needed
10 }
11
12 fn test2<T1, T2>(arg1 : T1, arg2 : T2) {
13   let foo : Foo::<T1, T2 = Foo {_a : arg1, _b : arg2};
14     //~^ ERROR: expected one of
15 }
16
17 fn test3<'a>(arg : &'a u32) {
18   let v : Vec<'a = vec![];
19     //~^ ERROR: expected one of
20     //~| ERROR: type annotations needed for `Vec<T>`
21 }
22
23 fn main() {}