In my program, I create dynamic lambda expressions and then compile them to delegates. These delegates are then invoked to extract information from my entities. Some of the delegates may throw exceptions, I've caught the exception where I call the delegate. I've enabled "Enable just my code" and applied [DebuggerNonUserCode] attribute to where the LambdaExpression is created, where compiled, and where Called. But because in Debug>Exceptions>Common Language Runtime Exceptions, the Thrown check box is checked, visual studio always stops on the error, which is a major inconvenience for the developers.
It seems that [DebuggerNonUserCode] should somehow be applied to the compiled delegate, but how? Or any other suggestion?
Thanks.