MCPcopy Create free account
hub / github.com/brimdata/super / Equal

Method Equal

value.go:297–307  ·  view source on GitHub ↗

Equal reports whether p and v have the same type and the same BSUP representation.

(p Value)

Source from the content-addressed store, hash-verified

295// Equal reports whether p and v have the same type and the same BSUP
296// representation.
297func (v Value) Equal(p Value) bool {
298 if v.Type() != p.Type() {
299 return false
300 }
301 if x, ok := v.native(); ok {
302 if y, ok := p.native(); ok {
303 return x == y
304 }
305 }
306 return bytes.Equal(v.Bytes(), p.Bytes())
307}
308
309func (r Value) HasField(field string) bool {
310 return TypeRecordOf(r.Type()).HasField(field)

Callers 15

IsMissingMethod · 0.45
IsQuietMethod · 0.45
NormalizeMapFunction · 0.45
NormalizeSetFunction · 0.45
runOneBoomerangFunction · 0.45
equalMethod · 0.45
TestRecordAccessNamedFunction · 0.45
TestDuplicatesFunction · 0.45
TestTranslateNamedFunction · 0.45
NewRecordBuilderFunction · 0.45
isInFunction · 0.45

Calls 4

TypeMethod · 0.95
nativeMethod · 0.95
BytesMethod · 0.95
TypeMethod · 0.65

Tested by 15

runOneBoomerangFunction · 0.36
TestRecordAccessNamedFunction · 0.36
TestDuplicatesFunction · 0.36
TestTranslateNamedFunction · 0.36
TestDictRebuildDropTagsFunction · 0.36
TestBitsGetBitsFunction · 0.36
TestQueryFunction · 0.36
TestQueryEmptyPoolFunction · 0.36
TestPoolStatsFunction · 0.36
TestPoolStatsNoDataFunction · 0.36