Arglist parseArglist() {
    Arglist arglist = new Arglist();
    while (true) {
      if (at("*")) {
        if (arglist.restPositionals != null || arglist.restKeywords != null) {
          throw new ParserException();
        }
        arglist.setRestPositionals(parseTest());
      } else if (at("**")) {
        if (arglist.restKeywords != null) {
          throw new ParserException();
        }
        arglist.setRestKeywords(parseTest());
      } else {
        if (is(",") || is(")")) {
          break;
        }
        parseArgument(arglist);
      }
      if (!at(",")) {
        break;
      }
    }
    return arglist;
  }