2021-10-14 06:53:20 +00:00
|
|
|
#![feature(staged_api)]
|
|
|
|
#![feature(const_eval_select)]
|
2022-04-11 18:12:26 -07:00
|
|
|
#![feature(core_intrinsics)]
|
2021-10-14 06:53:20 +00:00
|
|
|
#![stable(since = "1.0", feature = "ui_test")]
|
|
|
|
|
|
|
|
use std::intrinsics::const_eval_select;
|
|
|
|
|
|
|
|
fn log() {
|
|
|
|
println!("HEY HEY HEY")
|
|
|
|
}
|
|
|
|
|
|
|
|
const fn nothing(){}
|
|
|
|
|
|
|
|
#[stable(since = "1.0", feature = "hey")]
|
|
|
|
#[rustc_const_stable(since = "1.0", feature = "const_hey")]
|
2024-03-02 12:53:28 +01:00
|
|
|
pub const fn hey() {
|
2021-10-14 06:53:20 +00:00
|
|
|
const_eval_select((), nothing, log);
|
2024-10-06 19:59:19 +02:00
|
|
|
//~^ ERROR cannot use `#[feature(const_eval_select)]`
|
2021-10-14 06:53:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|