yum-mirror/glslang
git clone https://git.yummers.dev/yum-mirror/glslang
a496a34b
main-tot
1#version 460 2 3out int outx ; 4int counter = 0 ; 5 6void test_if () { 7if ( false ) { 8counter += 1 ; 9} 10} 11 12void test_ifelse () { 13if ( false ) { 14counter += 1 ; 15} 16else { 17counter += 2 ; 18} 19} 20 21void test_if_compound () { 22if ( false ) { 23if ( false ) { 24counter += 1 ; 25} 26} 27} 28 29void test_if_compound2 () { 30if ( false ) { 31if ( false ) { 32counter += 1 ; 33} 34 35counter += 2 ; 36} 37} 38 39void test_switch () { 40switch ( 0 ) { 41case 0 : 42counter += 1 ; 43// implict fallthrough 44case 1 : 45counter += 2 ; 46break ; 47default : 48counter += 3 ; 49// implicit break 50} 51} 52 53void main () { 54test_if () ; 55test_ifelse () ; 56test_if_compound () ; 57test_if_compound2 () ; 58test_switch () ; 59outx = counter ; 60}