Implementing IEnumerable<T>
Hi all!
I'm trying to simplify a complex return type that I have to repeat in a lot of places
Although I'm pleased with how the type allows me to easily package and aggregate errors that I encounter without having to throw and catch them, the length of the type does no favours to the code's readability.
I sought to start to simplify the type a bit by contracting
down to
Which I tried to implement using the following code
Although the code compiles, once I started to update the code I use to generate an
Then I hit
I'm trying to simplify a complex return type that I have to repeat in a lot of places
Result<IEnumerable<Result<TRow, Faults<TDataFault>>>, Faults<TMetadatFault>>Although I'm pleased with how the type allows me to easily package and aggregate errors that I encounter without having to throw and catch them, the length of the type does no favours to the code's readability.
I sought to start to simplify the type a bit by contracting
IEnumerable<Result<TRow, Faults<TDataFault>>>down to
IRowSeq<TRow, TDataFault>Which I tried to implement using the following code
Although the code compiles, once I started to update the code I use to generate an
IEnumerableThen I hit
csharp(CS1624) the body of (method) cannot be an iterator block because 'IRowSeq<TRow, TDataFault>' is not an iterator interface type