Example #1
0
 public override void Emit(EmissionStream stream)
 {
     stream.WriteLine(";DCPUB FUNCTION " + functionName + " " + entranceLabel + " " + parameterCount);
     base.Emit(stream);
     stream.WriteLine(";END FUNCTION");
     stream.WriteLine("");
 }
Example #2
0
File: Node.cs Project: Blecki/DCPUB
 public virtual void EmitIR(EmissionStream stream, bool Tidy)
 {
     if (!Tidy) stream.WriteLine("[generic node]");
     stream.indentDepth += 1;
     foreach (var child in children) child.EmitIR(stream, Tidy);
     stream.indentDepth -= 1;
     if (!Tidy) stream.WriteLine("[/generic node]");
 }
Example #3
0
 public override void EmitIR(EmissionStream stream, bool Tidy)
 {
     if (!Tidy) stream.WriteLine("[function node]");
     stream.WriteLine(";DCPUB FUNCTION " + functionName + " " + entranceLabel + " " + parameterCount);
     base.EmitIR(stream, Tidy);
     stream.WriteLine(";END FUNCTION");
     if (!Tidy) stream.WriteLine("[/function node]");
     stream.WriteLine("");
 }
Example #4
0
 public override void EmitIR(EmissionStream stream, bool Tidy)
 {
     if (Tidy) return;
     var commentLines = comment.Split(new char[] { '\n', '\r' }, StringSplitOptions.RemoveEmptyEntries);
     foreach (var line in commentLines)
         stream.WriteLine("[a /] ; " + line);
 }
Example #5
0
 public override void Emit(EmissionStream stream)
 {
     var commentLines = comment.Split(new char[] { '\n', '\r' }, StringSplitOptions.RemoveEmptyEntries);
     foreach (var line in commentLines)
         stream.WriteLine("; " + line);
 }
Example #6
0
File: Node.cs Project: Blecki/DCPUB
 public override void EmitIR(EmissionStream stream, bool Tidy)
 {
     if (!Tidy) stream.WriteLine("[transient node]");
     stream.indentDepth += 1;
     foreach (var child in children) child.EmitIR(stream, Tidy);
     stream.indentDepth -= 1;
     if (!Tidy) stream.WriteLine("[/transient node]");
 }
Example #7
0
 public override void EmitIR(EmissionStream stream, bool Tidy)
 {
     var str = "DAT " + String.Join(" ", data);
     stream.WriteLine(str);
 }