Skip to content

Commit 280bac8

Browse files
committed
const folding: compiletest div by 0 causes ICE
1 parent d6913d8 commit 280bac8

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
// build-pass
2+
3+
#![allow(unconditional_panic)]
4+
5+
use spirv_std::spirv;
6+
7+
#[spirv(fragment)]
8+
pub fn const_fold_div(out: &mut u32) {
9+
*out = 7u32 / 0;
10+
}

0 commit comments

Comments
 (0)