Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there an Expression Tree Visualizer for VS 2012?

Is there an Expression Tree Visualizer for VS 2012? Have had a search but have found the VS 2008 popping up all over the place, and the new VS 2012 doesn't have a Visualizers folder in the installation directory. Or, am I missing something that I should be able to switch on?

like image 699
Neil Knight Avatar asked Apr 17 '12 08:04

Neil Knight


People also ask

What is AC expression tree?

Expression trees represent code in a tree-like data structure, where each node is an expression, for example, a method call or a binary operation such as x < y . You can compile and run code represented by expression trees.

Where is the expression tree used?

Expression Trees provide richer interaction with the arguments that are functions. You write function arguments, typically using Lambda Expressions, when you create LINQ queries. In a typical LINQ query, those function arguments are transformed into a delegate the compiler creates.


1 Answers

What you can do is fix the visualizer for vs 2010 so it works in 2012. This is very easy. Just get the source from this project : http://exprtreevisualizer.codeplex.com/ and change the DebuggerVisualizers assembly reference of the ExpressionTreeViewer project to :

C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\ReferenceAssemblies\v2.0\Microsoft.VisualStudio.DebuggerVisualizers.dll

So that it works with the newest version of vs2012. After that copy the results to

C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\Packages\Debugger\Visualizers

and it should work

like image 91
Gluip Avatar answered Oct 13 '22 12:10

Gluip