optimization for EnumerateCollection