Simplified.
Equals and hashcode impls of various registries.
Type fix.
Optimise for registries of only one entry.