public static bool equals(this StringElement s, object d) { return(s.Equals(d) && (d is StringElement) && realisationsMatch((StringElement)s, (StringElement)d)); }