error[E0308]: mismatched types --> $DIR/point-at-inference.rs:12:9 | LL | foo.push(i); | - this is of type `&{integer}`, which causes `foo` to be inferred as `Vec<&{integer}>` ... LL | bar(foo); | --- ^^^ expected `Vec`, found `Vec<&{integer}>` | | | arguments to this function are incorrect | = note: expected struct `Vec` found struct `Vec<&{integer}>` note: function defined here --> $DIR/point-at-inference.rs:2:4 | LL | fn bar(_: Vec) {} | ^^^ ----------- help: consider dereferencing the borrow | LL | foo.push(*i); | + error: aborting due to previous error For more information about this error, try `rustc --explain E0308`.