mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
![]() On nightly, we mention the trait is unstable ``` error[E0277]: the trait bound `T: Unstable` is not satisfied --> $DIR/unstable-trait-suggestion.rs:13:9 | LL | foo(t) | --- ^ the trait `Unstable` is not implemented for `T` | | | required by a bound introduced by this call | note: required by a bound in `foo` --> $DIR/unstable-trait-suggestion.rs:9:11 | LL | fn foo<T: Unstable>(_: T) {} | ^^^^^^^^ required by this bound in `foo` help: consider restricting type parameter `T` but it is an `unstable` trait | LL | pub fn demo<T: Unstable>(t: T) { | ++++++++++ ``` On stable, we don't suggest the trait at all ``` error[E0277]: the trait bound `T: Unstable` is not satisfied --> $DIR/unstable-trait-suggestion.rs:13:9 | LL | foo(t) | --- ^ the trait `Unstable` is not implemented for `T` | | | required by a bound introduced by this call | note: required by a bound in `foo` --> $DIR/unstable-trait-suggestion.rs:9:11 | LL | fn foo<T: Unstable>(_: T) {} | ^^^^^^^^ required by this bound in `foo` ``` |
||
---|---|---|
.. | ||
tuple-struct-fields | ||
add-tuple-within-arguments.rs | ||
add-tuple-within-arguments.stderr | ||
array-diagnostics.rs | ||
array-diagnostics.stderr | ||
builtin-fail.rs | ||
builtin-fail.stderr | ||
builtin.rs | ||
index-float.rs | ||
index-invalid.rs | ||
index-invalid.stderr | ||
indexing-in-macro.rs | ||
nested-index.rs | ||
one-tuple.rs | ||
tup.rs | ||
tuple-arity-mismatch.rs | ||
tuple-arity-mismatch.stderr | ||
tuple-index-fat-types.rs | ||
tuple-index-not-tuple.rs | ||
tuple-index-not-tuple.stderr | ||
tuple-index-out-of-bounds.rs | ||
tuple-index-out-of-bounds.stderr | ||
tuple-index.rs | ||
wrong_argument_ice-2.rs | ||
wrong_argument_ice-2.stderr | ||
wrong_argument_ice-3.rs | ||
wrong_argument_ice-3.stderr | ||
wrong_argument_ice-4.rs | ||
wrong_argument_ice-4.stderr | ||
wrong_argument_ice.rs | ||
wrong_argument_ice.stderr |