Explorar o código

Fix AsyncEnumerableQuery to support ValueTask<T> aggregates.

Bart De Smet %!s(int64=6) %!d(string=hai) anos
pai
achega
1db4db95d3

+ 1 - 1
Ix.NET/Source/System.Linq.Async.Queryable/System/Linq/AsyncEnumerableQuery.cs

@@ -103,7 +103,7 @@ namespace System.Linq
                 throw new ArgumentNullException(nameof(expression));
             }
 
-            if (!typeof(Task<TResult>).IsAssignableFrom(expression.Type))
+            if (!typeof(ValueTask<TResult>).IsAssignableFrom(expression.Type))
             {
                 throw new ArgumentException("The specified expression is not assignable to the result type.", nameof(expression));
             }