Hash returns a hash value for the given data type. Two types have the same hash if: - both types have the same kind - array types have elements whose types have the same hash - map types have keys and elements whose types have the same hash - user types have the same name if ignoreNames is false or
(dt DataType, ignoreFields, ignoreNames, ignoreTags bool)
| 30 | // - user types have the same attribute names and the attribute types have the same hash if ignoreFields is false |
| 31 | // - object attributes have the same "struct:field:xxx" tags if ignoreTags is false |
| 32 | func Hash(dt DataType, ignoreFields, ignoreNames, ignoreTags bool) string { |
| 33 | return *hash(dt, ignoreFields, ignoreNames, ignoreTags, make(map[*Object]*string)) |
| 34 | } |
| 35 | |
| 36 | func hash(dt DataType, ignoreFields, ignoreNames, ignoreTags bool, seen map[*Object]*string) *string { |
| 37 | if seen == nil { |