Skip to content

#598 Add end-user documentation on switch statements.

Closes #598 (closed).

I am in doubt what a good location in the tutorial is. On the one hand, it is an expression, so it should fit into the 'values' chapter, as that contains a general discussion on the terms 'type', 'value', and 'expression'. But this chapter does not contain any sections on which kinds of expressions are possible.

On the other hand, the notion of the if expression is actually explained in the functions chapter. Since the if expression and the switch expression are conceptually very close together, I ended up adding the documentation under the functions chapter.

Merge request reports

Loading