Exemplo n.º 1
0
        public static void Write(SwitchCaseExpression switchCaseExpression, IndentedStreamWriter writer)
        {
            writer.WriteLine($"({switchCaseExpression.Expression}) switch");
            writer.OpenBrackets();

            foreach (CaseExpression @case in switchCaseExpression.CaseExpressions)
            {
                writer.WriteLine($"{@case.Case} => {@case.Body},");
            }

            if (switchCaseExpression.DefaultCaseBody is { })
Exemplo n.º 2
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.Write("CallIndirect [{0}]({1})", TargetMethod, String.Join(", ", Sources));
			if (ReturnValueDestination != null)
				wtr.Write(" -> {0}", ReturnValueDestination);
			wtr.WriteLine();
		}
Exemplo n.º 3
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.Write("Return");
			if (Source != null)
				wtr.Write(" {0} {1}", SourceType, Source);
			wtr.WriteLine();
		}
Exemplo n.º 4
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Unary {0} {1}{2} -> {3}", ArgumentType, GetOperationSymbol(Operation), Source, Destination);
		}
Exemplo n.º 5
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("BranchTrue {0} -> {1}", Source, Target);
		}
Exemplo n.º 6
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("DEAD");
		}
Exemplo n.º 7
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Math {0} {1} {2} {3} -> {4}", ArgumentType, SourceA, GetOperationSymbol(Operation), SourceB, Destination);
		}
Exemplo n.º 8
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Branch -> {0}", Target);
		}
Exemplo n.º 9
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("BranchIndirect [{0}]", Source);
		}
Exemplo n.º 10
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Convert {0} {1} -> {2} {3}", SourceType, Source, DestinationType, Destination);
		}
Exemplo n.º 11
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Move {0} {1} -> {2}", ArgumentType, Source, Destination);
		}
Exemplo n.º 12
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("Compare {0} {1} {2} -> {3}", SourceA, GetConditionSymbol(Condition), SourceB, Destination);
		}
Exemplo n.º 13
0
		internal override void Dump(IndentedStreamWriter wtr)
		{
			wtr.WriteLine("// {0}", Text);
		}