File tree Expand file tree Collapse file tree 3 files changed +14
-2
lines changed Expand file tree Collapse file tree 3 files changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,6 @@ pub(crate) fn path_to_const(
100
100
} ;
101
101
Some ( ConstData { ty, value } . intern ( Interner ) )
102
102
}
103
- Some ( ValueNs :: ConstId ( c) ) => db. const_eval ( c) . ok ( ) ,
104
103
_ => None ,
105
104
}
106
105
}
Original file line number Diff line number Diff line change @@ -1744,3 +1744,15 @@ fn foo(b: Bar) {
1744
1744
"# ,
1745
1745
) ;
1746
1746
}
1747
+
1748
+ #[ test]
1749
+ fn regression_14305 ( ) {
1750
+ check_no_mismatches (
1751
+ r#"
1752
+ //- minicore: add
1753
+ trait Tr {}
1754
+ impl Tr for [u8; C] {}
1755
+ const C: usize = 2 + 2;
1756
+ "# ,
1757
+ ) ;
1758
+ }
Original file line number Diff line number Diff line change @@ -3277,13 +3277,14 @@ fn func() {
3277
3277
3278
3278
#[ test]
3279
3279
fn issue_14275 ( ) {
3280
+ // FIXME: evaluate const generic
3280
3281
check_types (
3281
3282
r#"
3282
3283
struct Foo<const T: bool>;
3283
3284
fn main() {
3284
3285
const B: bool = false;
3285
3286
let foo = Foo::<B>;
3286
- //^^^ Foo<false >
3287
+ //^^^ Foo<_ >
3287
3288
}
3288
3289
"# ,
3289
3290
) ;
You can’t perform that action at this time.
0 commit comments