Skip to content
This repository has been archived by the owner on May 23, 2024. It is now read-only.

ices/86719.rs: fixed with errors #1120

Merged
merged 1 commit into from
Feb 9, 2022
Merged

ices/86719.rs: fixed with errors #1120

merged 1 commit into from
Feb 9, 2022

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Feb 9, 2022

Issue: rust-lang/rust#86719

trait Bar {
    type E;
}
impl<S> Bar for S {
    type E = impl ;
    fn foo() -> Self::E {
        |_| true
    }
}
=== stdout ===
=== stderr ===
error: at least one trait must be specified
 --> /home/runner/work/glacier/glacier/ices/86719.rs:5:14
  |
5 |     type E = impl ;
  |              ^^^^

error[E0407]: method `foo` is not a member of trait `Bar`
 --> /home/runner/work/glacier/glacier/ices/86719.rs:6:5
  |
6 | /     fn foo() -> Self::E {
7 | |         |_| true
8 | |     }
  | |_____^ not a member of trait `Bar`

error[E0658]: `impl Trait` in type aliases is unstable
 --> /home/runner/work/glacier/glacier/ices/86719.rs:5:14
  |
5 |     type E = impl ;
  |              ^^^^
  |
  = note: see issue #63063 <https://github.com/rust-lang/rust/issues/63063> for more information
  = help: add `#![feature(type_alias_impl_trait)]` to the crate attributes to enable

error[E0601]: `main` function not found in crate `86719`
 --> /home/runner/work/glacier/glacier/ices/86719.rs:1:1
  |
1 | / trait Bar {
2 | |     type E;
3 | | }
4 | | impl<S> Bar for S {
... |
8 | |     }
9 | | }
  | |_^ consider adding a `main` function to `/home/runner/work/glacier/glacier/ices/86719.rs`

error[E0282]: type annotations needed
 --> /home/runner/work/glacier/glacier/ices/86719.rs:7:10
  |
7 |         |_| true
  |          ^ consider giving this closure parameter a type

error: aborting due to 5 previous errors

Some errors have detailed explanations: E0282, E0407, E0601, E0658.
For more information about an error, try `rustc --explain E0282`.
==============

=== stdout ===
=== stderr ===
error: at least one trait must be specified
 --> /home/runner/work/glacier/glacier/ices/86719.rs:5:14
  |
5 |     type E = impl ;
  |              ^^^^

error[E0407]: method `foo` is not a member of trait `Bar`
 --> /home/runner/work/glacier/glacier/ices/86719.rs:6:5
  |
6 | /     fn foo() -> Self::E {
7 | |         |_| true
8 | |     }
  | |_____^ not a member of trait `Bar`

error[E0658]: `impl Trait` in type aliases is unstable
 --> /home/runner/work/glacier/glacier/ices/86719.rs:5:14
  |
5 |     type E = impl ;
  |              ^^^^
  |
  = note: see issue #63063 <rust-lang/rust#63063> for more information
  = help: add `#![feature(type_alias_impl_trait)]` to the crate attributes to enable

error[E0601]: `main` function not found in crate `86719`
 --> /home/runner/work/glacier/glacier/ices/86719.rs:1:1
  |
1 | / trait Bar {
2 | |     type E;
3 | | }
4 | | impl<S> Bar for S {
... |
8 | |     }
9 | | }
  | |_^ consider adding a `main` function to `/home/runner/work/glacier/glacier/ices/86719.rs`

error[E0282]: type annotations needed
 --> /home/runner/work/glacier/glacier/ices/86719.rs:7:10
  |
7 |         |_| true
  |          ^ consider giving this closure parameter a type

error: aborting due to 5 previous errors

Some errors have detailed explanations: E0282, E0407, E0601, E0658.
For more information about an error, try `rustc --explain E0282`.
==============
@Alexendoo Alexendoo merged commit 06c8426 into master Feb 9, 2022
@Alexendoo Alexendoo deleted the autofix/ices/86719.rs branch February 9, 2022 12:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants