Remix.run Logo
klysm 2 days ago

> if we are concerned about the underlying data shifting when the collection is actually enumerated

I’m not sure what you mean by this. You can fulfill the IEnumerable contract without allowing multiple enumerations, but that doesn’t really have to do with the data shifting around. Doing ToList can be an expensive and unnecessary allocation

bob1029 2 days ago | parent [-]

Imagine a live SQL query you are subsequently filtering with LINQ.

klysm 11 hours ago | parent [-]

Then the ToList will force it to be evaluated on the client - not sure that situation applies