Example #1
0
            /// <summary>
            /// It runs the analysis.
            /// It is there because so we can use the typebinding, and make the code less verbose
            /// </summary>
            internal static IMethodResult <Variable> HelperForStringAnalysis
            (
                string methodName,
                IMethodDriver <Local, Parameter, Method, Field, Property, Event, Type, Attribute, Assembly, Expression, Variable, ILogOptions> driver,
                IValueAnalysisOptions options,
                Predicate <APC> cachePCs, DFAController controller
            )
            {
                var analysis = new StringValueAnalysis(methodName, driver, options, cachePCs);

                var closure = driver.HybridLayer.CreateForward(analysis, new DFAOptions {
                    Trace = false
                }, controller);

                closure(analysis.GetTopValue()); // Do the analysis

                return(analysis);
            }