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

ices/91745.sh: fixed with no errors #1056

Merged
merged 1 commit into from
Dec 15, 2021
Merged

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#91745

#!/bin/bash

rustc -Zmir-opt-level=3 --crate-type lib - <<'EOF'
pub trait Foo {
    type Bar;
}

pub trait Broken {
    type Assoc;
    fn broken(&self) where Self::Assoc: Foo;
}

impl<T> Broken for T {
    type Assoc = ();
    fn broken(&self) where Self::Assoc: Foo {
        let _x: <Self::Assoc as Foo>::Bar;
    }
}

fn main() {
    let _m: &dyn Broken<Assoc=()> = &();
}
EOF
=== stdout ===
=== stderr ===
warning: function is never used: `main`
  --> <anon>:17:4
   |
17 | fn main() {
   |    ^^^^
   |
   = note: `#[warn(dead_code)]` on by default

warning: 1 warning emitted

==============

=== stdout ===
=== stderr ===
warning: function is never used: `main`
  --> <anon>:17:4
   |
17 | fn main() {
   |    ^^^^
   |
   = note: `#[warn(dead_code)]` on by default

warning: 1 warning emitted

==============
@Alexendoo Alexendoo merged commit 2d63a5d into master Dec 15, 2021
@Alexendoo Alexendoo deleted the autofix/ices/91745.sh branch December 15, 2021 20:23
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