module Zeitwerk::Registry

def inception?(cpath)

Other tags:
    Private: -
def inception?(cpath)
  if pair = inceptions[cpath]
    pair.first
  end
end

def loader_for(path)

Other tags:
    Private: -
def loader_for(path)
  autoloads[path]
end

def loader_for_gem(root_file, namespace:, warn_on_extra_files:)

Other tags:
    Private: -
def loader_for_gem(root_file, namespace:, warn_on_extra_files:)
  gem_loaders_by_root_file[root_file] ||= GemLoader.__new(root_file, namespace: namespace, warn_on_extra_files: warn_on_extra_files)
end

def on_unload(loader)

Other tags:
    Private: -
def on_unload(loader)
  autoloads.delete_if { |_path, object| object == loader }
  inceptions.delete_if { |_cpath, (_path, object)| object == loader }
end

def register_autoload(loader, abspath)

Other tags:
    Private: -
def register_autoload(loader, abspath)
  autoloads[abspath] = loader
end

def register_inception(cpath, abspath, loader)

Other tags:
    Private: -
def register_inception(cpath, abspath, loader)
  inceptions[cpath] = [abspath, loader]
end

def register_loader(loader)

Other tags:
    Private: -
def register_loader(loader)
  loaders << loader
end

def unregister_autoload(abspath)

Other tags:
    Private: -
def unregister_autoload(abspath)
  autoloads.delete(abspath)
end

def unregister_loader(loader)

Other tags:
    Private: -
def unregister_loader(loader)
  loaders.delete(loader)
  gem_loaders_by_root_file.delete_if { |_, l| l == loader }
  autoloads.delete_if { |_, l| l == loader }
  inceptions.delete_if { |_, (_, l)| l == loader }
end