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

ices/99348.rs: fixed with errors #1350

Merged
merged 1 commit into from
Jul 19, 2022
Merged

ices/99348.rs: fixed with errors #1350

merged 1 commit into from
Jul 19, 2022

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#99348

#![feature(type_alias_impl_trait)]

struct Concrete;

type Tait = impl Sized;

impl Foo for Concrete {
    type Item = Concrete;
}

impl Bar for Concrete {
    type Other = Tait;
}

trait Foo {
    type Item: Bar<Other = Self>;
}

trait Bar {
    type Other;
}

fn tait() -> Tait {}

pub fn main() {}
=== stdout ===
=== stderr ===
error[E0308]: mismatched types
 --> /home/runner/work/glacier/glacier/ices/99348.rs:8:17
  |
5 | type Tait = impl Sized;
  |             ---------- the expected opaque type
...
8 |     type Item = Concrete;
  |                 ^^^^^^^^ types differ
  |
  = note: expected opaque type `Tait`
                  found struct `Concrete`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0308`.
==============

=== stdout ===
=== stderr ===
error[E0308]: mismatched types
 --> /home/runner/work/glacier/glacier/ices/99348.rs:8:17
  |
5 | type Tait = impl Sized;
  |             ---------- the expected opaque type
...
8 |     type Item = Concrete;
  |                 ^^^^^^^^ types differ
  |
  = note: expected opaque type `Tait`
                  found struct `Concrete`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0308`.
==============
@JohnTitor JohnTitor merged commit 02d3290 into master Jul 19, 2022
@JohnTitor JohnTitor deleted the autofix/ices/99348.rs branch July 19, 2022 06:46
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