public void DeclareVariable(string name,Type value) { if(_variables.ContainsKey(name)) throw new SemanticException("Variable " + name + " already exist"); _variables[name] = value; _values[name] = value.GetDefaultValue(); }
public ArrayType(Type ofType, List<int> dim ) { OfType = ofType; Dimensions = dim; }