]> git.lizzy.rs Git - rust.git/blob - src/test/ui/typeck/issue-89856.stderr
Rollup merge of #95308 - bjorn3:more_stable_proc_macro, r=Mark-Simulacrum
[rust.git] / src / test / ui / typeck / issue-89856.stderr
1 error[E0308]: mismatched types
2   --> $DIR/issue-89856.rs:6:20
3    |
4 LL |     take_str_maybe(option);
5    |                    ^^^^^^ expected `str`, found struct `String`
6    |
7    = note: expected enum `Option<&str>`
8               found enum `Option<&String>`
9 help: try converting the passed type into a `&str`
10    |
11 LL |     take_str_maybe(option.map(|x| &**x));
12    |                          ++++++++++++++
13
14 error: aborting due to previous error
15
16 For more information about this error, try `rustc --explain E0308`.