function newSyntaxError(message) {
  return new SyntaxError(
    message + ', got "' + chop(token, 30) + '" (char ' + index + ")"
  );
}
Create a syntax error with extra information on current token and index.
@param {string} message
@returns {SyntaxError} err