mirror of
https://github.com/rust-lang-cn/book-cn.git
synced 2025-02-02 23:38:41 +08:00
18 lines
654 B
Plaintext
18 lines
654 B
Plaintext
$ cargo run
|
|
Compiling deref-example v0.1.0 (file:///projects/deref-example)
|
|
error[E0277]: can't compare `{integer}` with `&{integer}`
|
|
--> src/main.rs:6:5
|
|
|
|
|
6 | assert_eq!(5, y);
|
|
| ^^^^^^^^^^^^^^^^^ no implementation for `{integer} == &{integer}`
|
|
|
|
|
= help: the trait `PartialEq<&{integer}>` is not implemented for `{integer}`
|
|
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error: aborting due to previous error
|
|
|
|
For more information about this error, try `rustc --explain E0277`.
|
|
error: could not compile `deref-example`
|
|
|
|
To learn more, run the command again with --verbose.
|