question: protected void recoverFile ( ) throws IOException { while ( true ) { switch ( token ) { case CLASS : case INTERFACE : return ; case LBRACE : match ( LBRACE , RBRACE ) ; scan ( ) ; break ; case LPAREN : match ( LPAREN , RPAREN ) ; scan ( ) ; break ; case LSQBRACKET : match ( LSQBRACKET , RSQBRACKET ) ; scan ( ) ; break ; case EOF : return ; default : scan ( ) ; break ; } } }
target:  Recover after a syntax error in the file. This involves discarding tokens until an EOF or a possible legal continuation is encountered.