]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-35668.stderr
Merge commit '61667dedf55e3e5aa584f7ae2bd0471336b92ce9' into sync_cg_clif-2021-09-19
[rust.git] / src / test / ui / issues / issue-35668.stderr
1 error[E0369]: cannot multiply `&T` by `&T`
2   --> $DIR/issue-35668.rs:2:23
3    |
4 LL |     a.iter().map(|a| a*a)
5    |                      -^- &T
6    |                      |
7    |                      &T
8    |
9 help: consider restricting type parameter `T`
10    |
11 LL | fn func<'a, T: std::ops::Mul<Output = &T>>(a: &'a [T]) -> impl Iterator<Item=&'a T> {
12    |              ++++++++++++++++++++++++++++
13
14 error: aborting due to previous error
15
16 For more information about this error, try `rustc --explain E0369`.