Optimized object manager handling in YAML.pm.