]> git.proxmox.com Git - rustc.git/blame - src/test/ui/rfc-1937-termination-trait/termination-trait-test-wrong-type.stderr
New upstream version 1.52.0~beta.3+dfsg1
[rustc.git] / src / test / ui / rfc-1937-termination-trait / termination-trait-test-wrong-type.stderr
CommitLineData
6a06907d 1error[E0277]: `main` has invalid return type `Result<f32, ParseFloatError>`
ba9703b0 2 --> $DIR/termination-trait-test-wrong-type.rs:6:1
83c7162d 3 |
48663c56 4LL | / fn can_parse_zero_as_f32() -> Result<f32, ParseFloatError> {
83c7162d
XL
5LL | | "0".parse()
6LL | | }
1b1a35ee 7 | |_^ `main` can only return types that implement `Termination`
e1599b0c 8 |
3dfed10e 9 ::: $SRC_DIR/test/src/lib.rs:LL:COL
e1599b0c
XL
10 |
11LL | pub fn assert_test_result<T: Termination>(result: T) {
1b1a35ee 12 | ----------- required by this bound in `assert_test_result`
83c7162d 13 |
6a06907d 14 = help: the trait `Termination` is not implemented for `Result<f32, ParseFloatError>`
74b04a01 15 = note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info)
83c7162d
XL
16
17error: aborting due to previous error
18
19For more information about this error, try `rustc --explain E0277`.