]> git.proxmox.com Git - rustc.git/blob - src/test/compile-fail/issue-20616-1.rs
Imported Upstream version 1.0.0+dfsg1
[rustc.git] / src / test / compile-fail / issue-20616-1.rs
1 // Copyright 2015 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
4 //
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
10
11 // We need all these 9 issue-20616-N.rs files
12 // becase we can only catch one parsing error at a time
13
14
15
16 type Type_1_<'a, T> = &'a T;
17
18
19 type Type_1<'a T> = &'a T; //~ error: expected `,` or `>` after lifetime name, found `T`
20
21
22 //type Type_2 = Type_1_<'static ()>; // error: expected `,` or `>` after lifetime name, found `(`
23
24
25 //type Type_3<T> = Box<T,,>; // error: expected type, found `,`
26
27
28 //type Type_4<T> = Type_1_<'static,, T>; // error: expected type, found `,`
29
30
31 type Type_5_<'a> = Type_1_<'a, ()>;
32
33
34 //type Type_5<'a> = Type_1_<'a, (),,>; // error: expected type, found `,`
35
36
37 //type Type_6 = Type_5_<'a,,>; // error: expected type, found `,`
38
39
40 //type Type_7 = Box<(),,>; // error: expected type, found `,`
41
42
43 //type Type_8<'a,,> = &'a (); // error: expected ident, found `,`
44
45
46 //type Type_9<T,,> = Box<T>; // error: expected ident, found `,`