MCPcopy Create free account
hub / github.com/decomp/decomp / Prim

Method Prim

cfa/if_else.go:42–55  ·  view source on GitHub ↗

Prim returns a representation of the high-level control flow primitive, as a mapping from control flow primitive node names to control flow graph node names. Example mapping: "cond": "A" "body_true": "B" "body_false": "C" "exit": "D"

()

Source from the content-addressed store, hash-verified

40// "body_false": "C"
41// "exit": "D"
42func (prim IfElse) Prim() *primitive.Primitive {
43 cond, bodyTrue, bodyFalse, exit := label(prim.Cond), label(prim.BodyTrue), label(prim.BodyFalse), label(prim.Exit)
44 return &primitive.Primitive{
45 Prim: "if_else",
46 Nodes: map[string]string{
47 "cond": cond,
48 "body_true": bodyTrue,
49 "body_false": bodyFalse,
50 "exit": exit,
51 },
52 Entry: cond,
53 Exit: exit,
54 }
55}
56
57// String returns a string representation of prim in DOT format.
58//

Callers

nothing calls this directly

Calls 1

labelFunction · 0.70

Tested by

no test coverage detected