Пример #1
0
        public static void itoa()
        {
            SAR exp = SAS.Pop();

            if (exp.dataType != "int")
            {
                SemanticAtoiError(exp);
            }
            string[] data = { "returnType:char", "accessMod:private" };
            Symbol   temp = new Symbol("t", "t" + uniqueCounter++, "t" + exp.value, "tvar", data);

            SymbolTable.Add(temp);
            ICode.MOV(temp.symid, exp.symid);
            ICode.CONVERT(temp.symid);
            exp.dataType = "char";
            exp.symid    = temp.symid;
            SAS.Push(exp);
        }