Beispiel #1
0
        private static void validateExecutionPath(INode node, ExecutionPath path,
                                                  ComputationContext ctx, ref ValidationData result)
        {
            bool first = true;

            foreach (IEvaluable step in path)
            {
                if (!first)
                {
                    ctx.ValAssignTracker?.ResetBranches();
                }

                if (!result.UnreachableCodeFound && result.IsTerminated)
                {
                    result.UnreachableCodeFound = true;
                    ctx.AddError(ErrorCode.UnreachableCode, step);
                }

                ValidationData val = Validated(step, ctx);

                result.AddStep(val);

                first = false;
            }
        }