add test for ICE: no entry found for key for const function in generic_const_exprs #113133
Fixes #113133
This commit is contained in:
parent
8ed5e6744f
commit
cdea6d8382
@ -0,0 +1,13 @@
|
||||
// ICE no entry found for key generics_of
|
||||
// issue: rust-lang/rust#113133
|
||||
|
||||
#![allow(incomplete_features)]
|
||||
#![feature(generic_const_exprs, non_lifetime_binders)]
|
||||
|
||||
pub fn foo()
|
||||
where
|
||||
for<const N: usize = { const fn bar() {} bar(); 1 }> ():,
|
||||
//~^ ERROR defaults for generic parameters are not allowed in `for<...>` binders
|
||||
{}
|
||||
|
||||
fn main() {}
|
@ -0,0 +1,8 @@
|
||||
error: defaults for generic parameters are not allowed in `for<...>` binders
|
||||
--> $DIR/no-entry-found-for-key-ice-gce-nlb-113133.rs:9:9
|
||||
|
|
||||
LL | for<const N: usize = { const fn bar() {} bar(); 1 }> ():,
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: aborting due to 1 previous error
|
||||
|
Loading…
x
Reference in New Issue
Block a user