1 error[E0423]: expected value, found trait `SomeTrait`
4 LL | let trait_obj: &SomeTrait = SomeTrait;
5 | ^^^^^^^^^ not a value
7 error[E0038]: the trait `SomeTrait` cannot be made into an object
10 LL | let trait_obj: &SomeTrait = SomeTrait;
11 | ^^^^^^^^^^ the trait `SomeTrait` cannot be made into an object
13 = note: method `foo` has no receiver
15 error[E0033]: type `&dyn SomeTrait` cannot be dereferenced
16 --> $DIR/E0033.rs:11:9
18 LL | let &invalid = trait_obj;
19 | ^^^^^^^^ type `&dyn SomeTrait` cannot be dereferenced
21 error: aborting due to 3 previous errors
23 Some errors occurred: E0033, E0038, E0423.
24 For more information about an error, try `rustc --explain E0033`.