function processRequirements(requirements, module) {
  const runtimeKit = new Set()
  const runtimeFlags = {}

  for (const requirement of requirements) {
    // requirements can be more precise than just `module` - webpack will list nested fields in requirements, meanwhile we're only interested in passing the top level references.
    const requirementReferenceName = requirement.split('.')[0]
    if (requirementReferenceName === RUNTIME_GLOBALS.thisAsExports) {
      runtimeFlags.thisAsExports = true
      continue
    }
    if (requirementReferenceName === RUNTIME_GLOBALS.returnExportsFromRuntime) {
      // TODO: should be doable to introduce support in wrapper.js by conditionally adding a return statement. feels too niche to support
      continue
    }
    if (requirementReferenceName === '__webpack_exports__') {
      runtimeKit.add(module.exportsArgument)
    } else if (requirementReferenceName === 'module') {
      runtimeKit.add(module.moduleArgument)
    } else {
      runtimeKit.add(requirementReferenceName)
    }
  }
  diag.run(2, () => {
    runtimeKit.add(`/* ${Array.from(requirements).join()} */`)
  })

  return { runtimeKit, runtimeFlags }
}
@param {Set<string>} requirements
@param {NormalModule} module
@returns