fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0599]: no method named `finish` found for struct `DefaultHasher` in the current scope 2 --> $DIR/import-trait-for-method-call.rs:6:7 3 | 4LL | h.finish() 5 | ^^^^^^ method not found in `DefaultHasher` 6 --> $SRC_DIR/core/src/hash/mod.rs:LL:COL 7 | 8 = note: the method is available for `DefaultHasher` here 9 | 10 = help: items from traits can only be used if the trait is in scope 11help: the following trait is implemented but not in scope; perhaps add a `use` for it: 12 | 13LL + use std::hash::Hasher; 14 | 15 16error[E0599]: the method `as_ref` exists for reference `&dyn Bar`, but its trait bounds were not satisfied 17 --> $DIR/import-trait-for-method-call.rs:15:7 18 | 19LL | trait Bar {} 20 | --------- doesn't satisfy `dyn Bar: AsRef<_>` 21... 22LL | x.as_ref(); 23 | ^^^^^^ method cannot be called on `&dyn Bar` due to unsatisfied trait bounds 24 | 25 = note: the following trait bounds were not satisfied: 26 `dyn Bar: AsRef<_>` 27 which is required by `&dyn Bar: AsRef<_>` 28 = help: items from traits can only be used if the trait is implemented and in scope 29 = note: the following trait defines an item `as_ref`, perhaps you need to implement it: 30 candidate #1: `AsRef` 31 32error: aborting due to 2 previous errors 33 34For more information about this error, try `rustc --explain E0599`.