remove FIXME and add test
This commit is contained in:
parent
ce5ed5b6cc
commit
71362c733f
@ -344,8 +344,6 @@ where
|
|||||||
};
|
};
|
||||||
|
|
||||||
// Check the qualifs of the value of `const` items.
|
// Check the qualifs of the value of `const` items.
|
||||||
// FIXME(valtrees): check whether const qualifs should behave the same
|
|
||||||
// way for type and mir constants.
|
|
||||||
let uneval = match constant.literal {
|
let uneval = match constant.literal {
|
||||||
ConstantKind::Ty(ct)
|
ConstantKind::Ty(ct)
|
||||||
if matches!(
|
if matches!(
|
||||||
|
12
tests/ui/match/issue-113012.rs
Normal file
12
tests/ui/match/issue-113012.rs
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
// run-pass
|
||||||
|
|
||||||
|
#![allow(dead_code)]
|
||||||
|
struct Foo(());
|
||||||
|
|
||||||
|
const FOO: Foo = Foo(match 0 {
|
||||||
|
0.. => (),
|
||||||
|
_ => (),
|
||||||
|
});
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user