about summary refs log tree commit diff
path: root/tests/ui/methods/clone-missing.stderr
blob: 8676e73c8ca25016ea4cddde886cef6567fb8838 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
error[E0599]: no method named `clone` found for struct `NotClone` in the current scope
  --> $DIR/clone-missing.rs:28:16
   |
LL | struct NotClone {
   | --------------- method `clone` not found for this struct
...
LL |     let _y = x.clone();
   |                ^^^^^ method not found in `NotClone`
   |
   = help: items from traits can only be used if the trait is implemented and in scope
   = note: the following trait defines an item `clone`, perhaps you need to implement it:
           candidate #1: `Clone`

error[E0599]: no method named `clone` found for struct `AlsoNotClone` in the current scope
  --> $DIR/clone-missing.rs:32:16
   |
LL | struct AlsoNotClone {
   | ------------------- method `clone` not found for this struct
...
LL |     let _y = x.clone();
   |                ^^^^^ method not found in `AlsoNotClone`
   |
   = help: items from traits can only be used if the trait is implemented and in scope
   = note: the following trait defines an item `clone`, perhaps you need to implement it:
           candidate #1: `Clone`

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0599`.