public override bool Equals(object obj) { var sv = obj as ScalarValue; if (sv == null) return false; return Equals(Value, sv.Value); }