// Equal returns true if the given option is equal to the instance one. In case
// the given option is nil, we checked the instance one is set to the default
// value of the option.
489394
func (o *PrimaryOption) Equal(o2 *PrimaryOption) bool {
	if o2 == nil {
		return o.value == ""
	}
	return o.value == o2.value
}
690004
func (o *ClusterNameOption) Equal(o2 *ClusterNameOption) bool {
	if o2 == nil {
		return o.value == ""
	}
	return o.value == o2.value
}
1036101
func (a *AggFuncDesc) Equal(ctx sessionctx.Context, other *AggFuncDesc) bool {
	if a.HasDistinct != other.HasDistinct {
		return false
	}
	return a.baseFuncDesc.equal(ctx, &other.baseFuncDesc)
}
1295661
func (o *AutoGenerateObjectIDIfNotExistOption) Equal(o2 *AutoGenerateObjectIDIfNotExistOption) bool {
	if o2 == nil {
		return o.value == false
	}
	return o.value == o2.value
}
232028
func (self StringEqualer) Equal(e Equaler) bool {
	return self.S == e.(StringEqualer).S
}
541482
func (d DummyEqualer) Equal(u Equaler) bool {
	_, ok := u.(DummyEqualer)
	return ok
}
316218
func (o *MinWordSizefor1TypoOption) Equal(o2 *MinWordSizefor1TypoOption) bool {
	if o2 == nil {
		return o.value == 4
	}
	return o.value == o2.value
}
245570
func Equal(a1, a2 interface{}) bool {
	if a1 == nil || a2 == nil {
		return a1 == a2
	}
	v1 := reflect.ValueOf(a1)
	v2 := reflect.ValueOf(a2)
	if v1.Type() != v2.Type() {
		return false
	}
	return deepValueEqual(v1, v2, make(map[visit]bool), 0)
}
225708
func Equal(t TestingT, expected, actual interface{}, msgAndArgs ...interface{}) bool {

	if !ObjectsAreEqual(expected, actual) {
		diff := diff(expected, actual)
		return Fail(t, fmt.Sprintf("Not equal: %#v (expected)\n"+
			"        != %#v (actual)%s", expected, actual, diff), msgAndArgs...)
	}

	return true

}
1136235
func (b *Boolean) Equal(value bool) *Boolean {
	if !(b.value == value) {
		b.chain.fail("expected boolean == %v, but got %v", value, b.value)
	}
	return b
}
96756
func (a *AttributeTypeAndValue) Equal(other *AttributeTypeAndValue) bool {
	return strings.EqualFold(a.Type, other.Type) && a.Value == other.Value
}
1041790
func (o *FacetingAfterDistinctOption) Equal(o2 *FacetingAfterDistinctOption) bool {
	if o2 == nil {
		return o.value == false
	}
	return o.value == o2.value
}
175432
func (opt Option) Equal(b Option) bool {
	if bytes.Equal(opt.Name, b.Name) {
		return opt.Parameters.Equal(b.Parameters)
	}
	return false
}
398146
func (o *MaxFacetHitsOption) Equal(o2 *MaxFacetHitsOption) bool {
	if o2 == nil {
		return o.value == 10
	}
	return o.value == o2.value
}
177807
func (o *AroundLatLngViaIPOption) Equal(o2 *AroundLatLngViaIPOption) bool {
	if o2 == nil {
		return o.value == false
	}
	return o.value == o2.value
}
115469
func (o *AttributeForDistinctOption) Equal(o2 *AttributeForDistinctOption) bool {
	if o2 == nil {
		return o.value == ""
	}
	return o.value == o2.value
}
1321475
func (o *SumOrFiltersScoresOption) Equal(o2 *SumOrFiltersScoresOption) bool {
	if o2 == nil {
		return o.value == false
	}
	return o.value == o2.value
}