fix stack overflow exception fired  in Collection.set with large collect...

re #2767