whole_func_string: function Promise(executor) {
    if (executor === promiseRawSymbol) {
      return %_NewObject(GlobalPromise, new.target);
    }
    if (IS_UNDEFINED(new.target)) throw MakeTypeError(kNotAPromise, this);
    if (!IS_CALLABLE(executor)) {
      throw MakeTypeError(kResolverNotAFunction, executor);
    }
  
    var promise = PromiseInit(%_NewObject(GlobalPromise, new.target));
    var callbacks = CreateResolvingFunctions(promise);
    var debug_is_active = DEBUG_IS_ACTIVE;
    try {
      if (debug_is_active) %DebugPushPromise(promise, Promise);
      executor(callbacks.resolve, callbacks.reject);
    } catch (e) {
      %_Call(callbacks.reject, UNDEFINED, e);
    } finally {
      if (debug_is_active) %DebugPopPromise();
    }
  
    return promise;
  }
func_code_string: function Promise(executor) {
    if (executor === promiseRawSymbol) {
      return %_NewObject(GlobalPromise, new.target);
    }
    if (IS_UNDEFINED(new.target)) throw MakeTypeError(kNotAPromise, this);
    if (!IS_CALLABLE(executor)) {
      throw MakeTypeError(kResolverNotAFunction, executor);
    }
  
    var promise = PromiseInit(%_NewObject(GlobalPromise, new.target));
    var callbacks = CreateResolvingFunctions(promise);
    var debug_is_active = DEBUG_IS_ACTIVE;
    try {
      if (debug_is_active) %DebugPushPromise(promise, Promise);
      executor(callbacks.resolve, callbacks.reject);
    } catch (e) {
      %_Call(callbacks.reject, UNDEFINED, e);
    } finally {
      if (debug_is_active) %DebugPopPromise();
    }
  
    return promise;
  }
func_documentation_string: ES#sec-promise-executor Promise ( executor )