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

ices/90319.rs: fixed with errors #1184

Merged
merged 1 commit into from
Mar 26, 2022
Merged

ices/90319.rs: fixed with errors #1184

merged 1 commit into from
Mar 26, 2022

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#90319

struct Wrapper<T>(T);

trait Trait {
    fn method(&self) {}
}

impl<'a, T> Trait for Wrapper<&'a T> where Wrapper<T>: Trait {}

fn get<T>() -> T {
    unimplemented!()
}

fn main() {
    let thing = get::<Thing>();
    let wrapper = Wrapper(thing);
    Trait::method(&wrapper);
}
=== stdout ===
=== stderr ===
error[E0412]: cannot find type `Thing` in this scope
  --> /home/runner/work/glacier/glacier/ices/90319.rs:14:23
   |
14 |     let thing = get::<Thing>();
   |                       ^^^^^ not found in this scope

error: aborting due to previous error

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

=== stdout ===
=== stderr ===
error[E0412]: cannot find type `Thing` in this scope
  --> /home/runner/work/glacier/glacier/ices/90319.rs:14:23
   |
14 |     let thing = get::<Thing>();
   |                       ^^^^^ not found in this scope

error: aborting due to previous error

For more information about this error, try `rustc --explain E0412`.
==============
@Alexendoo Alexendoo merged commit a6c0110 into master Mar 26, 2022
@Alexendoo Alexendoo deleted the autofix/ices/90319.rs branch March 26, 2022 12:50
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