MCPcopy Create free account
hub / github.com/google/gapid / LocalInit

Method LocalInit

core/codegen/builder.go:158–162  ·  view source on GitHub ↗

LocalInit returns a new local variable with the specified name and initial value.

(name string, val *Value)

Source from the content-addressed store, hash-verified

156
157// LocalInit returns a new local variable with the specified name and initial value.
158func (b *Builder) LocalInit(name string, val *Value) *Value {
159 local := b.Local(name, val.ty)
160 local.Store(val)
161 return local
162}
163
164// If builds an if statement.
165func (b *Builder) If(cond *Value, onTrue func()) {

Callers 15

ForNMethod · 0.95
expressionAddrMethod · 0.80
declareLocalMethod · 0.80
iterationMethod · 0.80
sliceAssignMethod · 0.80
doCastMethod · 0.80
castTargetToCaptureMethod · 0.80
castCaptureToTargetMethod · 0.80
buildMapMethod · 0.80
IterateMapMethod · 0.80
binaryOpMethod · 0.80
sliceIndexMethod · 0.80

Calls 2

LocalMethod · 0.95
StoreMethod · 0.65

Tested by

no test coverage detected