Skip to content

Commit

Permalink
Add regression test for #66596
Browse files Browse the repository at this point in the history
  • Loading branch information
varkor committed Apr 9, 2020
1 parent 485c5fb commit 61cc892
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
@@ -0,0 +1,16 @@
// check-pass

#![feature(const_generics)]
//~^ WARN the feature `const_generics` is incomplete and may cause the compiler to crash

trait Trait<const NAME: &'static str> {
type Assoc;
}

impl Trait<"0"> for () {
type Assoc = ();
}

fn main() {
let _: <() as Trait<"0">>::Assoc = ();
}
@@ -0,0 +1,8 @@
warning: the feature `const_generics` is incomplete and may cause the compiler to crash
--> $DIR/issue-66596-impl-trait-for-str-const-arg.rs:3:12
|
LL | #![feature(const_generics)]
| ^^^^^^^^^^^^^^
|
= note: `#[warn(incomplete_features)]` on by default

0 comments on commit 61cc892

Please sign in to comment.