@@ -74,13 +74,13 @@ def conjoinAll (exprs : List StmtExprMd) : StmtExprMd :=
7474 | first :: rest => rest.foldl (fun acc e => mkMd <| .PrimitiveOp .And [acc, e]) first
7575
7676/--
77- Pointwise frame: every allocated object the `modifies` clause does not name keeps
77+ Quantified (pointwise) frame: every allocated object the `modifies` clause does not name keeps
7878all of its field values across the call.
7979
8080 forall $obj: Composite, $fld: Field =>
8181 notModified($obj) && $obj < old($heap).nextReference ==> readField(old($heap), $obj, $fld) == readField($heap, $obj, $fld)
8282-/
83- def buildPointwiseFrame (proc : Procedure) (entries : List ModifiesEntry)
83+ def buildQuantifiedFrame (proc : Procedure) (entries : List ModifiesEntry)
8484 (heapIn heapOut : StmtExprMd) : StmtExprMd :=
8585 let objName : Identifier := "$modifies_obj"
8686 let fldName : Identifier := "$modifies_fld"
@@ -155,15 +155,15 @@ def transformModifiesClauses (model: SemanticModel)
155155 if useEnumeratedFrame && onlyIndividualRefs entries then
156156 -- Callers assume the quantifier-free frame; the body re-checks the
157157 -- pointwise frame at every exit.
158- let pointwise := buildPointwiseFrame proc entries heapIn heapOut
158+ let pointwise := buildQuantifiedFrame proc entries heapIn heapOut
159159 let framePost : Condition :=
160160 { condition := buildEnumeratedFrame proc entries heapIn heapOut,
161161 summary := "modifies clause" , free := true }
162162 let impl' := impl.map (insertFrameChecks proc pointwise)
163163 .ok { proc with body := .Opaque (postconds ++ [framePost]) impl' [] }
164164 else
165165 let framePost : Condition :=
166- { condition := buildPointwiseFrame proc entries heapIn heapOut,
166+ { condition := buildQuantifiedFrame proc entries heapIn heapOut,
167167 summary := "modifies clause" }
168168 .ok { proc with body := .Opaque (postconds ++ [framePost]) impl [] }
169169 else
0 commit comments