Exposed icon indicating copy to clipboard operation
Exposed copied to clipboard

preserve colection type

Open lure opened this issue 2 years ago • 2 comments

with call should not change the receiver type, this is not what it is called for :)

lure avatar Sep 02 '22 20:09 lure

The idea here was to return loaded entities when SizedIterable was provided. @lure , you think it's worth to return original collection for further chaining?

Tapac avatar Sep 09 '22 12:09 Tapac

I believe, having the type changed is a huge disadvantage.

  1. It breaks the type flow, and there is no reason for it. It is with not toIterableAndTransform.
  2. Handful of extension functions are now required to be either copy-pasted (b/c of type erasure) or go up the collection hierarchy to the point where the contract is broken.
  3. Note also, that while expecting the SizableIterable that type does not appear in the ext declaration.

lure avatar Sep 09 '22 13:09 lure