code: func (self *_parser) nextStatement() {
  	for {
  		switch self.token {
  		case token.BREAK, token.CONTINUE,
  			token.FOR, token.IF, token.RETURN, token.SWITCH,
  			token.VAR, token.DO, token.TRY, token.WITH,
  			token.WHILE, token.THROW, token.CATCH, token.FINALLY:
  			// Return only if parser made some progress since last
  			// sync or if it has not reached 10 next calls without
  			// progress. Otherwise consume at least one token to
  			// avoid an endless parser loop
  			if self.idx == self.recover.idx && self.recover.count < 10 {
  				self.recover.count++
  				return
  			}
  			if self.idx > self.recover.idx {
  				self.recover.idx = self.idx
  				self.recover.count = 0
  				return
  			}
  			// Reaching here indicates a parser bug, likely an
  			// incorrect token list in this function, but it only
  			// leads to skipping of possibly correct code if a
  			// previous error is present, and thus is preferred
  			// over a non-terminating parse.
  		case token.EOF:
  			return
  		}
  		self.next()
  	}
  }
docs: // Find the next statement after an error (recover)