func (v *validator) checkConflicts(cons Value) error {
	attrValues := cons.attributesWithValues()
	attrSet := make(set.Strings)
	for attrTag := range attrValues {
		attrSet.Add(attrTag)
	}
	for _, attrTag := range attrSet.SortedValues() {
		conflicts, ok := v.conflicts[attrTag]
		if !ok {
			continue
		}
		for _, conflict := range conflicts.SortedValues() {
			if attrSet.Contains(conflict) {
				return fmt.Errorf("ambiguous constraints: %q overlaps with %q", attrTag, conflict)
			}
		}
	}
	return nil
}
// checkConflicts returns an error if the constraints Value contains conflicting attributes.
checkConflicts returns an error if the constraints Value contains conflicting attributes.
// checkConflicts returns an error if the constraints Value contains conflicting attributes .
func (v *validator) checkConflicts(cons Value) error {
	attrValues := cons.attributesWithValues()
	attrSet := make(set.Strings)
	for attrTag := range attrValues {
		attrSet.Add(attrTag)
	}
	for _, attrTag := range attrSet.SortedValues() {
		conflicts, ok := v.conflicts[attrTag]
		if !ok {
			continue
		}
		for _, conflict := range conflicts.SortedValues() {
			if attrSet.Contains(conflict) {
				return fmt.Errorf("ambiguous constraints: %q overlaps with %q", attrTag, conflict)
			}
		}
	}
	return nil
}
func ( v * validator ) checkConflicts ( cons Value ) error { attrValues := cons . attributesWithValues ( ) attrSet := make ( set . Strings ) for attrTag := range attrValues { attrSet . Add ( attrTag ) } for _ , attrTag := range attrSet . SortedValues ( ) { conflicts , ok := v . conflicts [ attrTag ] if ! ok { continue } for _ , conflict := range conflicts . SortedValues ( ) { if attrSet . Contains ( conflict ) { return fmt . Errorf ( " " , attrTag , conflict ) } } } return nil }
checkConflicts returns an error if the constraints Value contains conflicting attributes.
checkConflicts returns an error if the constraints Value contains conflicting attributes .