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

ices/64537.rs: fixed with no errors #427

Merged
merged 1 commit into from
Jul 16, 2020
Merged

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#64537

#![feature(const_generics)]

struct S;

impl S {
    pub fn x<const I: usize>() {}
    pub fn y() {
        Self::x::<{3usize}>();
    }
}

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

warning: unnecessary braces around const expression
 --> /home/runner/work/glacier/glacier/ices/64537.rs:8:19
  |
8 |         Self::x::<{3usize}>();
  |                   ^^^^^^^^ help: remove these braces
  |
  = note: `#[warn(unused_braces)]` on by default

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

warning: associated function is never used: `x`
 --> /home/runner/work/glacier/glacier/ices/64537.rs:6:12
  |
6 |     pub fn x<const I: usize>() {}
  |            ^

warning: associated function is never used: `y`
 --> /home/runner/work/glacier/glacier/ices/64537.rs:7:12
  |
7 |     pub fn y() {
  |            ^

warning: 5 warnings emitted

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

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

warning: unnecessary braces around const expression
 --> /home/runner/work/glacier/glacier/ices/64537.rs:8:19
  |
8 |         Self::x::<{3usize}>();
  |                   ^^^^^^^^ help: remove these braces
  |
  = note: `#[warn(unused_braces)]` on by default

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

warning: associated function is never used: `x`
 --> /home/runner/work/glacier/glacier/ices/64537.rs:6:12
  |
6 |     pub fn x<const I: usize>() {}
  |            ^

warning: associated function is never used: `y`
 --> /home/runner/work/glacier/glacier/ices/64537.rs:7:12
  |
7 |     pub fn y() {
  |            ^

warning: 5 warnings emitted

==============
@Alexendoo Alexendoo merged commit 054d20e into master Jul 16, 2020
@Alexendoo Alexendoo deleted the autofix/ices/64537.rs branch July 16, 2020 12:51
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