summary refs log tree commit diff
path: root/src/test/ui/loops/loops-reject-labels-shadowing-lifetimes.stderr
blob: af524d5b01766e283937f36b9227509420acf6a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
warning: label name `'a` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:20:9
   |
LL |     fn foo<'a>() {
   |            -- first declared here
LL |         'a: loop { break 'a; }
   |         ^^ lifetime 'a already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:45:13
   |
LL |     impl<'bad, 'c> Struct<'bad, 'c> {
   |          ---- first declared here
LL |         fn meth_bad(&self) {
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:52:13
   |
LL |     impl<'b, 'bad> Struct<'b, 'bad> {
   |              ---- first declared here
LL |         fn meth_bad2(&self) {
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:59:13
   |
LL |         fn meth_bad3<'bad>(x: &'bad i8) {
   |                      ---- first declared here
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:64:13
   |
LL |         fn meth_bad4<'a,'bad>(x: &'a i8, y: &'bad i8) {
   |                         ---- first declared here
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:71:13
   |
LL |     impl <'bad, 'e> Enum<'bad, 'e> {
   |           ---- first declared here
LL |         fn meth_bad(&self) {
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:77:13
   |
LL |     impl <'d, 'bad> Enum<'d, 'bad> {
   |               ---- first declared here
LL |         fn meth_bad2(&self) {
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:83:13
   |
LL |         fn meth_bad3<'bad>(x: &'bad i8) {
   |                      ---- first declared here
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:88:13
   |
LL |         fn meth_bad4<'a,'bad>(x: &'bad i8) {
   |                         ---- first declared here
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:98:13
   |
LL |     trait HasDefaultMethod1<'bad> {
   |                             ---- first declared here
...
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:104:13
   |
LL |     trait HasDefaultMethod2<'a,'bad> {
   |                                ---- first declared here
LL |         fn meth_bad(&self) {
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

warning: label name `'bad` shadows a lifetime name that is already in scope
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:110:13
   |
LL |         fn meth_bad<'bad>(&self) {
   |                     ---- first declared here
LL |             'bad: loop { break 'bad; }
   |             ^^^^ lifetime 'bad already in scope

error: compilation successful
  --> $DIR/loops-reject-labels-shadowing-lifetimes.rs:117:1
   |
LL | / pub fn main() { //~ ERROR compilation successful
LL | |     foo();
LL | | }
   | |_^

error: aborting due to previous error