module Bootsnap::CompileCache::YAML::Patch

def load_file(path, *args)

def load_file(path, *args)
  return super if args.size > 1
  if kwargs = args.first
    return super unless kwargs.is_a?(Hash)
    return super unless (kwargs.keys - ::Bootsnap::CompileCache::YAML.supported_options).empty?
  end
  begin
    ::Bootsnap::CompileCache::Native.fetch(
      Bootsnap::CompileCache::YAML.cache_dir,
      File.realpath(path),
      ::Bootsnap::CompileCache::YAML,
      kwargs,
    )
  rescue Errno::EACCES
    ::Bootsnap::CompileCache.permission_error(path)
  end
end