Beispiel #1
0
        public static AdressType GetCurrentVariableAdressType()
        {
            AdressType res = new AdressType(currentAdressTypes[adressIDToAdd], currentAdressType);

            currentAdressTypes[adressIDToAdd]++;
            return(res);
        }
Beispiel #2
0
 public ASTvariable()
 {
     reloadedTimes   = 0;
     this.valType    = new ValueType(VT.Cunknown);
     this.name       = "-";
     this.adress     = new AdressType(-1, VAT.Unknown);
     this.localSpace = string.Join("/", MISC.nowParsing.ToArray());
     everUsed        = 0;
 }
Beispiel #3
0
 public ASTvariable(ValueType vt, string name, int level, AdressType adress)
 {
     reloadedTimes = 0;
     this.valType  = vt;
     this.name     = name;
     // check variable name with function collision
     for (int i = 0; i < ASTTree.funcs.Count; i++)
     {
         if (name == ASTTree.funcs[i].getName)
         {
             throw new Exception("Variable \"" + name + "\" can not conflict with function : " + ASTTree.funcs[i].getArgsString);
         }
     }
     //
     this.adress     = adress;//ASTTree.variables.Count;
     this.localSpace = string.Join("/", MISC.nowParsing.ToArray());
     everUsed        = 0;
 }