MCPcopy
hub / github.com/google/mangle / pair

Function pair

ast/ast.go:335–337  ·  view source on GitHub ↗

Pair constructs a pair constant. Parts can only be accessed in transforms.

(tpe ConstantType, fst, snd *Constant)

Source from the content-addressed store, hash-verified

333
334// Pair constructs a pair constant. Parts can only be accessed in transforms.
335func pair(tpe ConstantType, fst, snd *Constant) Constant {
336 return Constant{tpe, "", hashPair(fst, snd, tpe), fst, snd}
337}
338
339// Pair constructs a pair constant. Parts can only be accessed in transforms.
340func Pair(fst, snd *Constant) Constant {

Callers 4

PairFunction · 0.70
ListConsFunction · 0.70
MapConsFunction · 0.70
StructConsFunction · 0.70

Calls 1

hashPairFunction · 0.85

Tested by

no test coverage detected