parser: Use a switch statement for unescaping.