summaryrefslogtreecommitdiffstats
path: root/tests/ui/inline-const/expr-unsafe-err.rs
blob: adf05d352ea70c0f5f9602d965a5788e91601df1 (plain)
1
2
3
4
5
6
7
8
9
10
11
// revisions: mir thir
// [thir]compile-flags: -Z thir-unsafeck
#![feature(inline_const)]
const unsafe fn require_unsafe() -> usize { 1 }

fn main() {
    const {
        require_unsafe();
        //~^ ERROR [E0133]
    }
}