mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 15:23:46 +00:00
77 lines
3.0 KiB
Plaintext
77 lines
3.0 KiB
Plaintext
error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
|
|
--> $DIR/fn-trait-notation.rs:4:8
|
|
|
|
|
LL | F: Fn<i32, Output = i32>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^ help: use parenthetical notation instead: `Fn(i32) -> i32`
|
|
|
|
|
= note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
|
|
= help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
|
|
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
|
|
|
|
error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
|
|
--> $DIR/fn-trait-notation.rs:6:8
|
|
|
|
|
LL | G: Fn<(i32, i32, ), Output = (i32, i32)>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use parenthetical notation instead: `Fn(i32, i32) -> (i32, i32)`
|
|
|
|
|
= note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
|
|
= help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
|
|
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
|
|
|
|
error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
|
|
--> $DIR/fn-trait-notation.rs:7:8
|
|
|
|
|
LL | H: Fn<(i32,), Output = i32>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^ help: use parenthetical notation instead: `Fn(i32) -> i32`
|
|
|
|
|
= note: see issue #29625 <https://github.com/rust-lang/rust/issues/29625> for more information
|
|
= help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
|
|
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
|
|
|
|
error[E0059]: type parameter to bare `Fn` trait must be a tuple
|
|
--> $DIR/fn-trait-notation.rs:4:8
|
|
|
|
|
LL | F: Fn<i32, Output = i32>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^ the trait `Tuple` is not implemented for `i32`
|
|
|
|
|
note: required by a bound in `Fn`
|
|
--> $SRC_DIR/core/src/ops/function.rs:LL:COL
|
|
|
|
error[E0059]: cannot use call notation; the first type parameter for the function trait is neither a tuple nor unit
|
|
--> $DIR/fn-trait-notation.rs:9:5
|
|
|
|
|
LL | f(3);
|
|
| ^^^^
|
|
|
|
error[E0277]: `i32` is not a tuple
|
|
--> $DIR/fn-trait-notation.rs:9:5
|
|
|
|
|
LL | f(3);
|
|
| ^^^^ the trait `Tuple` is not implemented for `i32`
|
|
|
|
error[E0308]: mismatched types
|
|
--> $DIR/fn-trait-notation.rs:17:5
|
|
|
|
|
LL | / e0658(
|
|
LL | | |a| a,
|
|
LL | | |a, b| (b, a),
|
|
LL | | |a| a,
|
|
LL | | );
|
|
| |_____^ types differ
|
|
|
|
|
= note: expected trait `Fn<i32>`
|
|
found trait `Fn(_)`
|
|
note: required by a bound in `e0658`
|
|
--> $DIR/fn-trait-notation.rs:4:8
|
|
|
|
|
LL | fn e0658<F, G, H>(f: F, g: G, h: H) -> i32
|
|
| ----- required by a bound in this function
|
|
LL | where
|
|
LL | F: Fn<i32, Output = i32>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^ required by this bound in `e0658`
|
|
|
|
error: aborting due to 7 previous errors
|
|
|
|
Some errors have detailed explanations: E0059, E0277, E0308, E0658.
|
|
For more information about an error, try `rustc --explain E0059`.
|