I have an implementation of IQueryProvider and have the following method:
public override IQueryable<T> CreateQuery<T>(System.Linq.Expressions.Expression expression)
{
return new System.Linq.EnumerableQuery<T>(this.Items);
}
The items property is defined as
public IEnumerable<T> Items { get; set; }
I get a cryptic compiler error for the EnumerableQuery constructor:
> Argument 1: cannot convert from
> 'System.Collections.Generic.IEnumerable<T>
> [c:\Windows\Microsoft.NET\Framework\v4.0.30319\mscorlib.dll]' to
> 'System.Collections.Generic.IEnumerable<T>> [c:\Windows\Microsoft.NET\Framework\v4.0.30319\mscorlib.dll]'
What am I doing wrong? I know it's likely to be wrapped up in the generics somewhere, but the arguments look the same to me!