]> git.lizzy.rs Git - rust.git/blob - src/test/ui/single-use-lifetime/one-use-in-fn-argument-in-band.stderr
Do not suggest using a const parameter when there are bounds on an unused type parameter
[rust.git] / src / test / ui / single-use-lifetime / one-use-in-fn-argument-in-band.stderr
1 error: lifetime parameter `'a` only used once
2   --> $DIR/one-use-in-fn-argument-in-band.rs:11:10
3    |
4 LL | fn a(x: &'a u32, y: &'b u32) {
5    |          ^^-
6    |          |
7    |          this lifetime is only used here
8    |          help: elide the single-use lifetime
9    |
10 note: the lint level is defined here
11   --> $DIR/one-use-in-fn-argument-in-band.rs:4:9
12    |
13 LL | #![deny(single_use_lifetimes)]
14    |         ^^^^^^^^^^^^^^^^^^^^
15
16 error: lifetime parameter `'b` only used once
17   --> $DIR/one-use-in-fn-argument-in-band.rs:11:22
18    |
19 LL | fn a(x: &'a u32, y: &'b u32) {
20    |                      ^^-
21    |                      |
22    |                      this lifetime is only used here
23    |                      help: elide the single-use lifetime
24
25 error: aborting due to 2 previous errors
26