2013-04-12 03:57:02 +00:00
|
|
|
#version 300 es
|
|
|
|
|
|
|
|
uniform int c, d;
|
2013-06-24 21:22:03 +00:00
|
|
|
in highp float x;
|
2013-04-12 03:57:02 +00:00
|
|
|
|
|
|
|
void main()
|
|
|
|
{
|
|
|
|
float f;
|
|
|
|
int a[2];
|
|
|
|
|
2013-06-26 05:54:40 +00:00
|
|
|
switch(f) { // ERROR
|
2013-04-12 03:57:02 +00:00
|
|
|
}
|
|
|
|
|
2013-06-26 05:54:40 +00:00
|
|
|
switch(a) { // ERROR
|
2013-04-12 03:57:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
switch(c)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2013-06-26 05:54:40 +00:00
|
|
|
switch(c) // ERROR, not enough stuff after last label
|
2013-04-12 03:57:02 +00:00
|
|
|
{
|
2013-06-26 05:54:40 +00:00
|
|
|
case 2:
|
2013-04-12 03:57:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
switch(c)
|
|
|
|
{
|
2013-06-26 05:54:40 +00:00
|
|
|
f = sin(x); // ERRROR
|
|
|
|
case 2:
|
2013-04-12 03:57:02 +00:00
|
|
|
f = cos(x);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
switch (c) {
|
2013-06-26 05:54:40 +00:00
|
|
|
default:
|
|
|
|
break;
|
2013-04-12 03:57:02 +00:00
|
|
|
case 1:
|
|
|
|
f = sin(x);
|
|
|
|
break;
|
|
|
|
case 2:
|
|
|
|
f = cos(x);
|
|
|
|
break;
|
2013-06-26 05:54:40 +00:00
|
|
|
default: // ERROR, 2nd default
|
2013-04-12 03:57:02 +00:00
|
|
|
f = tan(x);
|
|
|
|
}
|
|
|
|
|
|
|
|
switch (c) {
|
2013-06-26 05:54:40 +00:00
|
|
|
case 1:
|
|
|
|
f = sin(x);
|
|
|
|
break;
|
|
|
|
case 2:
|
|
|
|
switch (d) {
|
|
|
|
case 1:
|
|
|
|
f = x * x * x;
|
|
|
|
break;
|
|
|
|
case 2:
|
|
|
|
f = x * x;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
f = tan(x);
|
|
|
|
case 1: // ERROR, 2nd 'case 1'
|
|
|
|
break;
|
|
|
|
case 3.8: // ERROR, non-int
|
|
|
|
break;
|
|
|
|
case c: // ERROR, non-constant
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
switch (c) { // a no-error normal switch
|
2013-04-12 03:57:02 +00:00
|
|
|
case 1:
|
|
|
|
f = sin(x);
|
|
|
|
break;
|
|
|
|
case 2:
|
|
|
|
switch (d) {
|
|
|
|
case 1:
|
|
|
|
f = x * x * x;
|
|
|
|
break;
|
|
|
|
case 2:
|
|
|
|
f = x * x;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
f = tan(x);
|
|
|
|
}
|
|
|
|
|
2013-06-26 05:54:40 +00:00
|
|
|
break; // ERROR
|
2013-04-12 03:57:02 +00:00
|
|
|
}
|