File: function-body.stderr

package info (click to toggle)
rust-ref-cast 1.0.23-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 256 kB
  • sloc: makefile: 2
file content (13 lines) | stat: -rw-r--r-- 453 bytes parent folder | download | duplicates (14)
1
2
3
4
5
6
7
8
9
10
11
12
13
error: expected `;`
 --> tests/ui/function-body.rs:9:42
  |
9 |     pub fn ref_cast(s: &String) -> &Self {}
  |                                          ^

error[E0308]: mismatched types
 --> tests/ui/function-body.rs:9:36
  |
9 |     pub fn ref_cast(s: &String) -> &Self {}
  |            --------                ^^^^^ expected `&Thing`, found `()`
  |            |
  |            implicitly returns `()` as its body has no tail or `return` expression