Skip to content

Commit a8949ce

Browse files
Firestar99eddyb
authored andcommitted
const folding: compiletest div by 0 causes ICE
1 parent 7178adb commit a8949ce

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)