Skip to content

Commit

Permalink
Make argument order more robust.
Browse files Browse the repository at this point in the history
  • Loading branch information
gebner committed Oct 8, 2024
1 parent 24f4886 commit 40664bc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/pulse/lib/Pulse.Lib.Slice.fst
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ fn pts_to_len (#t: Type) (s: slice t) (#p: perm) (#v: Seq.seq t)
let is_from_array a s =
AP.is_from_array s.elt (SZ.v s.len) a

fn from_array (#t: Type) (a: array t) (#p: perm) (#v: Ghost.erased (Seq.seq t))
(alen: SZ.t { SZ.v alen == A.length a })
fn from_array (#t: Type) (a: array t) (#p: perm) (alen: SZ.t)
(#v: Ghost.erased (Seq.seq t) { SZ.v alen == A.length a })
requires A.pts_to a #p v
returns s: (slice t)
ensures
Expand Down
2 changes: 1 addition & 1 deletion lib/pulse/lib/Pulse.Lib.Slice.fsti
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ val pts_to_len (#t: Type) (s: slice t) (#p: perm) (#v: Seq.seq t) : stt_ghost un

val is_from_array (#t: Type) (a: array t) (s: slice t) : slprop

val from_array (#t: Type) (a: array t) (#p: perm) (#v: Ghost.erased (Seq.seq t)) (alen: SZ.t { SZ.v alen == A.length a }) : stt (slice t)
val from_array (#t: Type) (a: array t) (#p: perm) (alen: SZ.t) (#v: Ghost.erased (Seq.seq t) { SZ.v alen == A.length a }) : stt (slice t)
(A.pts_to a #p v)
(fun s -> pts_to s #p v ** is_from_array a s)

Expand Down

0 comments on commit 40664bc

Please sign in to comment.