(a, b reflect.Value)
| 36 | } |
| 37 | |
| 38 | func (s *syncMapDiffer) Match(a, b reflect.Value) bool { |
| 39 | st := reflect.TypeOf(&sync.Map{}) |
| 40 | |
| 41 | if !a.IsValid() || !b.IsValid() { |
| 42 | return false |
| 43 | } |
| 44 | if !a.CanInterface() || !b.CanInterface() { |
| 45 | return false |
| 46 | } |
| 47 | return reflect.TypeOf(a.Interface()) == st && reflect.TypeOf(b.Interface()) == st |
| 48 | } |
| 49 | |
| 50 | func (s *syncMapDiffer) Diff(dt diff.DiffType, df diff.DiffFunc, cl *diff.Changelog, path []string, a, b reflect.Value, parent interface{}) error { |
| 51 | // Checking what's been added |