Expression Tree Depth Restrictions

I had a problem calling Compile () in a LambdaExpression like Expression <Func <MyType, bool →, which has a depth of about 400. And a smaller value does not cause any problems. And I can not find anything about this restriction. Can anyone clarify this? Can I increase this limit?

UPD: Sorry, forgot to mention, I get a StackOverflowException:

An unhandled exception of type "System.StackOverflowException" occurred in System.Core.dll {The expression cannot be evaluated because the current thread is in state.}

+5
source share
1 answer
+3

All Articles