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

Method invalidate

runtime/sam/expr/values.go:231–244  ·  view source on GitHub ↗
(rec map[string]fieldValue)

Source from the content-addressed store, hash-verified

229}
230
231func (r *recordSpreadExpr) invalidate(rec map[string]fieldValue) {
232 n := len(rec)
233 r.fields = slices.Grow(r.fields[:0], n)[:n]
234 r.vals = slices.Grow(r.vals[:0], n)[:n]
235 for name, fv := range rec {
236 typ := fv.none
237 if typ == nil {
238 typ = fv.value.Type()
239 }
240 r.fields[fv.index] = super.NewFieldWithOpt(name, typ, fv.opt)
241 r.vals[fv.index] = fv
242 }
243 r.cache = r.sctx.MustLookupTypeRecord(r.fields)
244}
245
246type VectorElem struct {
247 Value Evaluator

Callers 1

updateMethod · 0.95

Calls 4

NewFieldWithOptFunction · 0.92
GrowMethod · 0.80
MustLookupTypeRecordMethod · 0.80
TypeMethod · 0.65

Tested by

no test coverage detected