// 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.
494811
func (o *MinWordSizefor2TyposOption) Equal(o2 *MinWordSizefor2TyposOption) bool {
	if o2 == nil {
		return o.value == 8
	}
	return o.value == o2.value
}
1170926
func (s *State) Equal(o *State) bool {
	return s.Enabled == o.Enabled &&
		s.Generation == o.Generation &&
		s.LastRewind.Equal(o.LastRewind) &&
		s.LastTick.Equal(&o.LastTick)
}
80816
func (o *MinimumAroundRadiusOption) Equal(o2 *MinimumAroundRadiusOption) bool {
	if o2 == nil {
		return o.value == 0
	}
	return o.value == o2.value
}
466954
func (self IntEqualer) Equal(e Equaler) bool {
	return self.I == e.(IntEqualer).I
}
370880
func (c *Constant) Equal(b Expression, ctx context.Context) bool {
	y, ok := b.(*Constant)
	if !ok {
		return false
	}
	con, err := c.Value.CompareDatum(ctx.GetSessionVars().StmtCtx, y.Value)
	if err != nil || con != 0 {
		return false
	}
	return true
}
1291636
func (o *SynonymsOption) Equal(o2 *SynonymsOption) bool {
	if o2 == nil {
		return o.value == true
	}
	return o.value == o2.value
}
101427
func (null Null) Equal(other Value) bool {
	switch other.(type) {
	case Null:
		return true
	default:
		return false
	}
}
59015
func (f Float) Equal(e Equaler) bool {
	ef := e.(Float)
	if f != f && ef != ef { // For our purposes NaN == NaN.
		return true
	}
	return f == ef
}
393083
func (bol Boolean) Equal(other Value) bool {
	switch other := other.(type) {
	case Boolean:
		return bol == other
	default:
		return false
	}
}
918823
func (s *OutputState) Equal(other *OutputState) bool {
	if s == nil && other == nil {
		return true
	}

	if s == nil || other == nil {
		return false
	}
	s.Lock()
	defer s.Unlock()

	if s.Type != other.Type {
		return false
	}

	if s.Sensitive != other.Sensitive {
		return false
	}

	if !reflect.DeepEqual(s.Value, other.Value) {
		return false
	}

	return true
}
489394
func (o *PrimaryOption) Equal(o2 *PrimaryOption) bool {
	if o2 == nil {
		return o.value == ""
	}
	return o.value == o2.value
}
285180
func (term *Term) Equal(other *Term) bool {
	if term == nil && other != nil {
		return false
	}
	if term != nil && other == nil {
		return false
	}
	if term == other {
		return true
	}
	return term.Value.Compare(other.Value) == 0
}
385221
func (o *RuleContextsOption) Equal(o2 *RuleContextsOption) bool {
	if o2 == nil {
		return reflect.DeepEqual(o.value, []string{})
	}
	return reflect.DeepEqual(o.value, o2.value)
}
1089901
func (o *ReplaceExistingSynonymsOption) Equal(o2 *ReplaceExistingSynonymsOption) bool {
	if o2 == nil {
		return o.value == false
	}
	return o.value == o2.value
}
461380
func (o *KeepDiacriticsOnCharactersOption) Equal(o2 *KeepDiacriticsOnCharactersOption) bool {
	if o2 == nil {
		return o.value == ""
	}
	return o.value == o2.value
}
1274687
func (o *PercentileComputationOption) Equal(o2 *PercentileComputationOption) bool {
	if o2 == nil {
		return o.value == true
	}
	return o.value == o2.value
}
933636
func (o *HitsPerPageOption) Equal(o2 *HitsPerPageOption) bool {
	if o2 == nil {
		return o.value == 20
	}
	return o.value == o2.value
}