Most general UnityContainer.RegisterType signature mismatch

Aug 13, 2010 at 10:23 PM
Hello, 

I just noticed that the most general UnityContainer.RegisterType (non-extension method) is missing the params keyword for the injectionMembers parameter:

public IUnityContainer RegisterType(Type from, Type to, string name, LifetimeManager lifetimeManager, InjectionMember[] injectionMembers);

This was a (small) source of confusion for me - the simpler overloads (extension methods) included the params, and a small generalization caused a compilation error.

Is this by design? Defensive programming against future API changes?  

Thanks, David
Aug 14, 2010 at 5:57 AM
No, unfortunately, it's just a silly mistake on my part. Although I suspect it's been there all along since we didn't actually change that overload from when it was first introduced. We'll add it to the list of things to tweak in the next release (which is probably not coming for a while).