try selectmany

pull/73/head
neuecc 2020-05-11 00:27:57 +09:00
parent 5db5beab29
commit 16c527fa89
3 changed files with 287 additions and 775 deletions

View File

@ -46,8 +46,21 @@ namespace Cysharp.Threading.Tasks.Linq
return false;
}
}
}
protected bool TryGetResult(UniTask.Awaiter awaiter)
{
try
{
awaiter.GetResult();
return true;
}
catch (Exception ex)
{
completionSource.TrySetException(ex);
return false;
}
}
}
public abstract class AsyncEnumeratorBase<TSource, TResult> : MoveNextSource, IUniTaskAsyncEnumerator<TResult>
{

File diff suppressed because it is too large Load Diff

View File

@ -305,11 +305,6 @@ namespace ___Dummy
public static IUniTaskAsyncEnumerable<TSource> Reverse<TSource>(this IUniTaskAsyncEnumerable<TSource> source)
{
throw new NotImplementedException();
}
public static IUniTaskAsyncEnumerable<TResult> SelectMany<TSource, TResult>(this IUniTaskAsyncEnumerable<TSource> source, Func<TSource, IUniTaskAsyncEnumerable<TResult>> selector)