views:

222

answers:

1

I'm trying to follow the instructions on Creating an IQueryable LINQ Provider, but when I implement the classes which inherit from ExpressionVisitor as instructed I am told that ExpressionVisitor is inaccessible due to its protection level. Am I missing something incredibly basic?

+2  A: 

The class is sealed, stupidly enough. Use the ExpressionVisitor at the end of this post instead. I can definitely recommend that walk-through, btw, it's really comprehensive and helpful in every way.

Good luck!

Banang
Thanks! I'm on my way to IQueryable goodness, but why on earth did the MSDN article want me to inherit a class that I couldn't?!
tags2k
I honestly don't know, I faced the same idiocraticy when I was doing this about a year ago. Have fun building your provider!
Banang
What a brilliant set of tutorials - I'm on #4 and I've already got an awesome provider. I guess you just can't rely on Microsoft to produce good tutorials themselves!
tags2k
I fully agree, Matt rocks! What are you building a provider for, if I may ask?
Banang
You probably already know this but just in case you don't, .NET 4.0 now exposes the MS implementation of ExpressionVisitor and have extended it somewhat.
Tim Jarvis