Ejemplo n.º 1
0
 public override string ToString()
 {
     if (Arg2 == null)
     {
         return("Log(" + "" + Arg1.ToString() + ")");
     }
     else
     {
         return("Log(" + "" + Arg1.ToString() + "," + Arg2.ToString() + ")");
     }
 }
Ejemplo n.º 2
0
        public override string ToString()
        {
            string str = "";

            switch (Op)
            {
            case Operator.COPY:
                str += "(COPY, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.MUL:
                str += "(*, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.DIV:
                str += "(/, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.ADD:
                str += "(+, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.SUB:
                str += "(-, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.NOT:
                str += "(not, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.PARAM:
                str += "(PARAM, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.GOTO:
                str += "(GOTO, " + "---" + ", " + Arg2.ToString() + ")";
                break;

            case Operator.IFTRUE:
                str += "(IFTRUE, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.IFFALSE:
                str += "(IFFALSE, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.CALL:
                str += "(CALL, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.LT:
                str += "(<, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.LE:
                str += "(<=, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.GT:
                str += "(>, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.GE:
                str += "(>=, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.EQ:
                str += "(=, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.NEQ:
                str += "(<>, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.FROMARRAY:
                str += "(FROMARRAY, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.TOARRAY:
                str += "(TOARRAY, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.RETURN:
                str += "(RETURN, " + "---" + ", " + "---" + ")";
                break;

            case Operator.RETVAL:
                str += "(RETURN, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.CONTINUE:
                if (Arg1 != null && Arg2 != null)
                {
                    str += "(CONTINUE, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                }
                else if (Arg1 != null)
                {
                    str += "(CONTINUE, " + Arg1.ToString() + ", " + "---" + ")";
                }
                else     // if (Arg2 != null)
                {
                    str += "(CONTINUE, " + "---" + ", " + Arg2.ToString() + ")";
                }
                break;

            case Operator.INC:     // Não usado no MiniPascal
                str += "(++, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.DEC:     // Não usado no MiniPascal
                str += "(--, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.NEG:     // Não usado no MiniPascal
                str += "(-, " + Arg1.ToString() + ", " + "---" + ")";
                break;

            case Operator.IFEXP:     // Não usado no MiniPascal
                str += "(IFEXP)";
                break;

            case Operator.ADDRESS:     // Não usado no MiniPascal
                str += "(&, " + Arg1.ToString() + ", " + Arg2.ToString() + ")";
                break;

            case Operator.FROMMEMORY:     // Não usado no MiniPascal
                str += "(FROMMEMORY)";
                break;

            case Operator.TOMEMORY:     // Não usado no MiniPascal
                str += "(TOMEMORY)";
                break;
            }

            return(str);
        }
Ejemplo n.º 3
0
 protected override string toString(int depth)
 {
     return(functionName + "(" + Arg1.ToString(depth) + "; " + Arg2.ToString(depth) + ")");
 }
Ejemplo n.º 4
0
 protected override string toString(int depth)
 {
     return(Arg1.ToString(depth, Priority) + " - " + Arg2.ToString(depth, Priority));
 }
Ejemplo n.º 5
0
 private void ReportDuration(System.Diagnostics.Stopwatch stopwatch, string suffix, string port)
 {
     System.Diagnostics.Debug.WriteLine(string.Format(port + ": COMMAND+{0} DURATION: {6} {1}(0x{2}, 0x{3}, 0x{4}, 0x{5})", suffix, Command, Arg0.ToString("X8"), Arg1.ToString("X8"), Arg2.ToString("X8"), Arg3.ToString("X8"), stopwatch.Elapsed));
 }
Ejemplo n.º 6
0
 public override string ToString() => "Cth(" + Arg1.ToString() + ")";
Ejemplo n.º 7
0
 public override string ToString() => "Actan(" + Arg1.ToString() + ")";
Ejemplo n.º 8
0
 public override string ToString() => "( " + Arg1.ToString() + " ^ " + Arg2.ToString() + " )";