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

ices/109790.rs: fixed with no errors #1580

Merged
merged 1 commit into from
May 9, 2023
Merged

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented May 9, 2023

Issue: rust-lang/rust#109790

#![feature(inherent_associated_types)]

struct Foo<T>(T);

impl<'a> Foo<fn(&'a ())> {
    type Assoc = &'a ();
}

trait Other {}
impl Other for u32 {}

fn bar(_: for<'a> fn(Foo<fn(&'a ())>::Assoc)) {}


fn main() {}
=== stdout ===
=== stderr ===
warning: the feature `inherent_associated_types` is incomplete and may not be safe to use and/or cause compiler crashes
 --> /home/runner/work/glacier/glacier/ices/109790.rs:1:12
  |
1 | #![feature(inherent_associated_types)]
  |            ^^^^^^^^^^^^^^^^^^^^^^^^^
  |
  = note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
  = note: `#[warn(incomplete_features)]` on by default

warning: struct `Foo` is never constructed
 --> /home/runner/work/glacier/glacier/ices/109790.rs:3:8
  |
3 | struct Foo<T>(T);
  |        ^^^
  |
  = note: `#[warn(dead_code)]` on by default

warning: associated type `Assoc` is never used
 --> /home/runner/work/glacier/glacier/ices/109790.rs:6:10
  |
5 | impl<'a> Foo<fn(&'a ())> {
  | ------------------------ associated type in this implementation
6 |     type Assoc = &'a ();
  |          ^^^^^

warning: function `bar` is never used
  --> /home/runner/work/glacier/glacier/ices/109790.rs:12:4
   |
12 | fn bar(_: for<'a> fn(Foo<fn(&'a ())>::Assoc)) {}
   |    ^^^

warning: 4 warnings emitted

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

=== stdout ===
=== stderr ===
warning: the feature `inherent_associated_types` is incomplete and may not be safe to use and/or cause compiler crashes
 --> /home/runner/work/glacier/glacier/ices/109790.rs:1:12
  |
1 | #![feature(inherent_associated_types)]
  |            ^^^^^^^^^^^^^^^^^^^^^^^^^
  |
  = note: see issue #8995 <rust-lang/rust#8995> for more information
  = note: `#[warn(incomplete_features)]` on by default

warning: struct `Foo` is never constructed
 --> /home/runner/work/glacier/glacier/ices/109790.rs:3:8
  |
3 | struct Foo<T>(T);
  |        ^^^
  |
  = note: `#[warn(dead_code)]` on by default

warning: associated type `Assoc` is never used
 --> /home/runner/work/glacier/glacier/ices/109790.rs:6:10
  |
5 | impl<'a> Foo<fn(&'a ())> {
  | ------------------------ associated type in this implementation
6 |     type Assoc = &'a ();
  |          ^^^^^

warning: function `bar` is never used
  --> /home/runner/work/glacier/glacier/ices/109790.rs:12:4
   |
12 | fn bar(_: for<'a> fn(Foo<fn(&'a ())>::Assoc)) {}
   |    ^^^

warning: 4 warnings emitted

==============
@JohnTitor JohnTitor merged commit 69b82db into master May 9, 2023
@JohnTitor JohnTitor deleted the autofix/ices/109790.rs branch May 9, 2023 09:13
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