getDeferredExports = (
  compartment,
  compartmentPrivateFields,
  moduleAliases,
  specifier,
) => {
  const { deferredExports } = compartmentPrivateFields;
  if (!mapHas(deferredExports, specifier)) {
    const deferred = deferExports();
    weakmapSet(
      moduleAliases,
      deferred.exportsProxy,
      makeAlias(compartment, specifier),
    );
    mapSet(deferredExports, specifier, deferred);
  }
  return mapGet(deferredExports, specifier);
}
Memoizes the creation of a deferred module exports namespace proxy for any
arbitrary full specifier in a compartment. It also records the compartment
and specifier affiliated with that module exports namespace proxy so it
can be used as an alias into another compartment when threaded through
a compartment's `moduleMap` argument.

@param {*} compartment - The compartment to retrieve deferred exports from.
@param {*} compartmentPrivateFields - The private fields of the compartment.
@param {*} moduleAliases - The module aliases of the compartment.
@param {string} specifier - The module specifier to retrieve deferred exports for.
@returns {DeferredExports} - The deferred exports for the module specifier of
the compartment.