code: function peek(p) {
      var i = p || 0, j = 0, t;
  
      while (j <= i) {
        t = lookahead[j];
        if (!t) {
          t = lookahead[j] = lex.token();
        }
        j += 1;
      }
      return t;
    }
docs: We need a peek function. If it has an argument, it peeks that much farther ahead. It is used to distinguish for ( var i in ... from for ( var i = ...