thrownewMultitonResolveException($"Can not resolve multiton without the first argument being the scope (should be of type {registration.Scope}).",typeof(T));
//if a multiton for the given scope exists return it
varinstances=_multitons.FirstOrDefault(m=>m.type==typeof(T)&&m.scope==registration.Scope).instances;//get instances for the given type and scope
varinstances=_multitons.FirstOrDefault(m=>m.type==registration.ImplementationType&&m.scope==registration.Scope).instances;//get instances for the given type and scope (use implementation type to resolve the correct instance for multiple multiton registrations as well)