error[E0658]: `match` is not allowed in a `const` --> $DIR/issue-46843.rs:11:20 | LL | pub const Q: i32 = match non_const() { | ____________________^ LL | | LL | | LL | | Thing::This => 1, LL | | Thing::That => 0 LL | | }; | |_^ | = note: see issue #49146 for more information = help: add `#![feature(const_if_match)]` to the crate attributes to enable error: aborting due to previous error For more information about this error, try `rustc --explain E0658`.