Last active
February 1, 2022 21:03
-
-
Save ihcsim/22028af6a0ef5d0b459b7b4b50a840fa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cargo run | |
Compiling rust-ownership v0.1.0 (/home/isim/rust-ownership) | |
error[E0507]: cannot move out of index of `Vec<Service>` | |
--> src/main.rs:19:17 | |
| | |
19 | let nginx = svcs[0]; | |
| ^^^^^^^ | |
| | | |
| move occurs because value has type `Service`, which does not implement the `Copy` trait | |
| help: consider borrowing here: `&svcs[0]` | |
For more information about this error, try `rustc --explain E0507`. | |
error: could not compile `rust-ownership` due to previous error |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment