Beispiel #1
0
        /// <summary>
        /// Rewrites a conditional goto statement.
        /// </summary>
        /// <param name="node">The conditional goto statement to rewrite.</param>
        /// <returns>The rewritten conditional goto statement.</returns>
        protected virtual BoundStatement RewriteConditionalGotoStatement(BoundConditionalGotoStatement node)
        {
            var condition = RewriteExpression(node.Condition);

            if (condition == node.Condition)
            {
                return(node);
            }

            return(new BoundConditionalGotoStatement(node.Label, condition, node.JumpIfTrue));
        }