Class OwnershipPathVerifier
It tracks OBLIGATIONS: an OWNED value (ValueKind.madeBy(IRInstr), or OWN v) is one, discharged by exactly
one consumer - DROP, DROP_AT_EXIT (handed to a region, which drops it at every exit, unwind
included), a [consume] assignment, an owned call argument, THROW, a forwarding CAST (the
obligation moves to the cast). Slots are their owners' (V-G), so they carry none.
Paths, compositionally (design §3): every nested list of a composite is CLOSED - what it makes it discharges, and it discharges nothing it was given. Flat branches inside a list are followed label by label, the state compared at every join and required empty at every RETURN. At every call - every call may throw until the effect summary exists - each live obligation must already be covered (handed to a region), or it leaks on that call's unwind edge.
Enforced (design §4, step 3): IR_ANALYSIS fails a compile on any finding, as it does for OwnershipVerifier.
-
Method Summary
Modifier and TypeMethodDescriptionThe per-path findings of one operation body.check(IRConstruct construct) The per-path findings of every operation of a construct, as"operation: problem"; empty when every path of every operation keeps V-A.
-
Method Details
-
check
The per-path findings of every operation of a construct, as"operation: problem"; empty when every path of every operation keeps V-A. -
check
-