protected DustObject(string typeName, DustType superType = null) : base(typeName, superType ?? DustTypes.Object) { }
public static DustType BestTypeFor(DustType type1, DustType type2) { return(type1.Rank > type2.Rank ? type1 : type2); }
public bool IsAssignableFrom(DustType type) { // TODO: Support multiple levels of inheritance return(this == type || this == type.SuperType); }
public bool Equals(DustType other) { return(TypeName == other.TypeName && SuperType == other.SuperType); }
protected DustType(string typeName, DustType superType = null) { TypeName = typeName; SuperType = superType; }