--- a/net/minecraft/core/HolderLookup.java
+++ b/net/minecraft/core/HolderLookup.java
@@ -53,7 +53,7 @@
             final Map<ResourceKey<? extends Registry<?>>, HolderLookup.RegistryLookup<?>> map = p_256054_.collect(
                 Collectors.toUnmodifiableMap(
                     HolderLookup.RegistryLookup::key,
-                    (Function<? super HolderLookup.RegistryLookup, ? extends HolderLookup.RegistryLookup>)(p_256335_ -> p_256335_)
+                    (p_256335_ -> p_256335_)
                 )
             );
             return new HolderLookup.Provider() {
