Ep.clearPendingException = function()

in packages/transform/src/emit.js [144:159]


Ep.clearPendingException = function(tryLoc, assignee) {
  const t = util.getTypes();

  t.assertLiteral(tryLoc);

  let catchCall = t.callExpression(
    this.contextProperty("catch", true),
    [t.clone(tryLoc)]
  );

  if (assignee) {
    this.emitAssign(assignee, catchCall);
  } else {
    this.emit(catchCall);
  }
};