fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0277]: the size for values of type `str` cannot be known at compilation time 2 --> $DIR/trivial-bounds-leak.rs:12:25 3 | 4LL | fn cant_return_str() -> str { 5 | ^^^ doesn't have a size known at compile-time 6 | 7 = help: the trait `Sized` is not implemented for `str` 8 = note: the return type of a function must have a statically known size 9 10error[E0599]: no method named `test` found for type `i32` in the current scope 11 --> $DIR/trivial-bounds-leak.rs:24:10 12 | 13LL | 3i32.test(); 14 | ^^^^ method not found in `i32` 15 | 16 = help: items from traits can only be used if the trait is implemented and in scope 17note: `Foo` defines an item `test`, perhaps you need to implement it 18 --> $DIR/trivial-bounds-leak.rs:4:1 19 | 20LL | pub trait Foo { 21 | ^^^^^^^^^^^^^ 22 23error[E0277]: the trait bound `i32: Foo` is not satisfied 24 --> $DIR/trivial-bounds-leak.rs:25:15 25 | 26LL | Foo::test(&4i32); 27 | --------- ^^^^^ the trait `Foo` is not implemented for `i32` 28 | | 29 | required by a bound introduced by this call 30 | 31help: this trait has no implementations, consider adding one 32 --> $DIR/trivial-bounds-leak.rs:4:1 33 | 34LL | pub trait Foo { 35 | ^^^^^^^^^^^^^ 36 37error[E0277]: the trait bound `i32: Foo` is not satisfied 38 --> $DIR/trivial-bounds-leak.rs:26:22 39 | 40LL | generic_function(5i32); 41 | ---------------- ^^^^ the trait `Foo` is not implemented for `i32` 42 | | 43 | required by a bound introduced by this call 44 | 45help: this trait has no implementations, consider adding one 46 --> $DIR/trivial-bounds-leak.rs:4:1 47 | 48LL | pub trait Foo { 49 | ^^^^^^^^^^^^^ 50note: required by a bound in `generic_function` 51 --> $DIR/trivial-bounds-leak.rs:29:24 52 | 53LL | fn generic_function<T: Foo>(t: T) {} 54 | ^^^ required by this bound in `generic_function` 55 56error: aborting due to 4 previous errors 57 58Some errors have detailed explanations: E0277, E0599. 59For more information about an error, try `rustc --explain E0277`.