File: unsupported_elided.stderr

package info (click to toggle)
rust-cxx 1.0.141-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,632 kB
  • sloc: cpp: 1,573; javascript: 124; sh: 11; makefile: 8
file content (22 lines) | stat: -rw-r--r-- 742 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
error[E0726]: implicit elided lifetime not allowed here
 --> tests/ui/unsupported_elided.rs:6:14
  |
6 |         type T;
  |              ^ expected lifetime parameter
  |
help: indicate the anonymous lifetime
  |
6 |         type T<'_>;
  |               ++++

error[E0106]: missing lifetime specifier
 --> tests/ui/unsupported_elided.rs:8:24
  |
8 |         fn f(t: &T) -> &str;
  |                 --     ^ expected named lifetime parameter
  |
  = help: this function's return type contains a borrowed value, but the signature does not say which one of `t`'s 2 lifetimes it is borrowed from
help: consider introducing a named lifetime parameter
  |
8 |         fn f<'a>(t: &'a T<'a>) -> &'a str;
  |             ++++     ++  ++++      ++