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

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#69654

#![feature(const_generics)]

trait Bar<O> {}
impl<O> Bar<O> for [u8; O] {}

struct Foo<const O: usize> {}
impl<const O: usize> Foo<O>
where
    [u8; O]: Bar<[(); O]>,
{
    fn foo() {}
}

fn main() {
    Foo::foo();
}
=== stdout ===
=== stderr ===
error[E0423]: expected value, found type parameter `O`
   --> /home/runner/work/glacier/glacier/ices/69654.rs:4:25
    |
4   | impl<O> Bar<O> for [u8; O] {}
    |                         ^ help: a tuple variant with a similar name exists: `Ok`

warning: the feature `const_generics` is incomplete and may cause the compiler to crash
 --> /home/runner/work/glacier/glacier/ices/69654.rs:1:12
  |
1 | #![feature(const_generics)]
  |            ^^^^^^^^^^^^^^
  |
  = note: `#[warn(incomplete_features)]` on by default

error: aborting due to previous error; 1 warning emitted

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

=== stdout ===
=== stderr ===
error[E0423]: expected value, found type parameter `O`
   --> /home/runner/work/glacier/glacier/ices/69654.rs:4:25
    |
4   | impl<O> Bar<O> for [u8; O] {}
    |                         ^ help: a tuple variant with a similar name exists: `Ok`

warning: the feature `const_generics` is incomplete and may cause the compiler to crash
 --> /home/runner/work/glacier/glacier/ices/69654.rs:1:12
  |
1 | #![feature(const_generics)]
  |            ^^^^^^^^^^^^^^
  |
  = note: `#[warn(incomplete_features)]` on by default

error: aborting due to previous error; 1 warning emitted

For more information about this error, try `rustc --explain E0423`.
==============
@hdhoang hdhoang merged commit 04f0b41 into master Apr 18, 2020
@Alexendoo Alexendoo deleted the autofix/ices/69654.rs branch April 18, 2020 14:28
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants