function makeParseFunction(doParse) {
  let cache = new Map();
  return (sourceLiterals, ...values) => {
    return parse(sourceLiterals, values, doParse, cache);
  };
}
@param {function(Parser) : ParseTree} doParse Function that calls the correct
    parse method on the parser.