Equivalent to the case statement in VHDL.switch (Expression)
{
case Val1:
case Val2:
...
break;
case Val3:
...
break;
case ValN:
...
break;
default:
...
break;
}
The switch statement can be specified inside a process or function. It uses C++ syntax and will be directly converted to a VHDL case statement.
If the expression used in the switch statement is of an enumeration type and you want to ensure that all cases have been considered, use the switchall statement.
See enum page for examples