コード例 #1
0
 protected internal virtual Expression VisitSwitch(SwitchCSharpStatement node) =>
 node.Update(
     Visit(node.SwitchValue),
     VisitLabelTarget(node.BreakLabel),
     VisitAndConvert(node.Variables, nameof(VisitSwitch)),
     Visit(node.Cases, VisitSwitchCase)
     );
コード例 #2
0
        protected internal override Expression VisitSwitch(SwitchCSharpStatement node)
        {
            var args = new List <object>();

            args.Add(new XElement(nameof(node.SwitchValue), Visit(node.SwitchValue)));

            if (node.Variables.Count > 0)
            {
                args.Add(Visit(nameof(node.Variables), node.Variables));
            }

            args.Add(Visit(nameof(node.Cases), node.Cases, Visit));

            args.Add(new XElement(nameof(node.BreakLabel), _parent.GetDebugView(node.BreakLabel)));

            return(Push(node, args));
        }
コード例 #3
0
 protected internal override Expression VisitSwitch(SwitchCSharpStatement node)
 {
     // NB: Nested switch statements end the reach of "goto case" and "goto default" statements.
     return(node);
 }
コード例 #4
0
 public SwitchCSharpStatementProxy(SwitchCSharpStatement node)
 {
     _node = node;
 }
コード例 #5
0
 public SwitchCSharpStatementProxy(SwitchCSharpStatement node)
 {
     _node = node;
 }
コード例 #6
0
 protected internal virtual Expression VisitSwitch(SwitchCSharpStatement node)
 {
     return node.Update(Visit(node.SwitchValue), VisitLabelTarget(node.BreakLabel), VisitAndConvert(node.Variables, nameof(VisitSwitch)), Visit(node.Cases, VisitSwitchCase));
 }
コード例 #7
0
 protected internal override Expression VisitSwitch(SwitchCSharpStatement node)
 {
     // NB: Nested switch statements end the reach of "goto case" and "goto default" statements.
     return node;
 }