コード例 #1
0
        private static void WriteLabelStatement(BoundLabelStatement node, IndentedTextWriter writer)
        {
            var unindent = writer.Indent > 0;

            if (unindent)
            {
                writer.Indent--;
            }

            writer.WritePunctuation(node.Label.Name);
            writer.WritePunctuation(SyntaxKind.ColonToken);
            writer.WriteLine();

            if (unindent)
            {
                writer.Indent++;
            }
        }
コード例 #2
0
ファイル: BoundTreeRewriter.cs プロジェクト: warappa/minsk
 protected virtual BoundStatement RewriteLabelStatement(BoundLabelStatement node)
 {
     return(node);
 }
コード例 #3
0
 public static BoundConditionalGotoStatement GotoIf(BoundLabelStatement label, BoundExpression condition, bool jumpIfTrue)
 {
     return(new BoundConditionalGotoStatement(label.Label, condition, jumpIfTrue));
 }
コード例 #4
0
 public static BoundConditionalGotoStatement GotoFalse(BoundLabelStatement label, BoundExpression condition)
 => GotoIf(label, condition, jumpIfTrue: false);
コード例 #5
0
 public static BoundGotoStatement Goto(BoundLabelStatement label)
 {
     return(new BoundGotoStatement(label.Label));
 }