nl_tokens: Reads a switch statement ebnf switch :: = T_SWITCH ( expr ) switch_case_list
pl_tokens: function ( ) { const result = this . node ( "switch" ) ; this . expect ( this . tok . T_SWITCH ) && this . next ( ) ; this . expect ( "(" ) && this . next ( ) ; const test = this . read_expr ( ) ; this . expect ( ")" ) && this . next ( ) ; const shortForm = this . <mask> === ":" ; const body = this . read_switch_case_list ( ) ; return result ( test , body , shortForm ) ; }