diff --git a/lib/steel/c/Steel.ST.C.Types.Fields.fsti b/lib/steel/c/Steel.ST.C.Types.Fields.fsti index 9371f7098..1a141e339 100644 --- a/lib/steel/c/Steel.ST.C.Types.Fields.fsti +++ b/lib/steel/c/Steel.ST.C.Types.Fields.fsti @@ -3,6 +3,11 @@ include Steel.ST.C.Types.Base open Steel.C.Typestring open Steel.ST.Util +[@@noextract_to "krml"] // tactic +let norm_fields () : FStar.Tactics.Tac unit = + FStar.Tactics.norm [delta_attr [`%norm_field_attr]; iota; zeta; primops]; + FStar.Tactics.trefl () + [@@noextract_to "krml"] // primitive val field_t_nil: Type0 [@@noextract_to "krml"] // primitive diff --git a/lib/steel/c/Steel.ST.C.Types.Struct.fsti b/lib/steel/c/Steel.ST.C.Types.Struct.fsti index cc0ceecaa..51875fe70 100644 --- a/lib/steel/c/Steel.ST.C.Types.Struct.fsti +++ b/lib/steel/c/Steel.ST.C.Types.Struct.fsti @@ -120,9 +120,31 @@ val has_struct_field (#fields: nonempty_field_description_t tf) (r: ref (struct0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') : Tot vprop +val has_struct_field_prop + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhost unit opened + (has_struct_field r field r') + (fun _ -> has_struct_field r field r') + True + (fun _ -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + ) + val has_struct_field_dup (#opened: _) (#tn: Type0) @@ -131,7 +153,9 @@ val has_struct_field_dup (#fields: nonempty_field_description_t tf) (r: ref (struct0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') : STGhostT unit opened (has_struct_field r field r') (fun _ -> has_struct_field r field r' `star` has_struct_field r field r') @@ -144,10 +168,15 @@ val has_struct_field_inj (#fields: nonempty_field_description_t tf) (r: ref (struct0 tn n fields)) (field: field_t fields) - (r1 r2: ref (fields.fd_typedef field)) -: STGhostT unit opened + (#t1: Type0) + (#td1: typedef t1) + (r1: ref td1) + (#t2: Type0) + (#td2: typedef t2) + (r2: ref td2) +: STGhostT (squash (t1 == t2 /\ td1 == td2)) opened (has_struct_field r field r1 `star` has_struct_field r field r2) - (fun _ -> has_struct_field r field r1 `star` has_struct_field r field r2 `star` ref_equiv r1 r2) + (fun _ -> has_struct_field r field r1 `star` has_struct_field r field r2 `star` ref_equiv r1 (coerce_eq () r2)) val has_struct_field_equiv_from (#opened: _) @@ -157,7 +186,9 @@ val has_struct_field_equiv_from (#fields: nonempty_field_description_t tf) (r1: ref (struct0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') (r2: ref (struct0 tn n fields)) : STGhostT unit opened (ref_equiv r1 r2 `star` has_struct_field r1 field r') @@ -171,8 +202,9 @@ val has_struct_field_equiv_to (#fields: nonempty_field_description_t tf) (r: ref (struct0 tn n fields)) (field: field_t fields) - (r1': ref (fields.fd_typedef field)) - (r2': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r1' r2': ref td') : STGhostT unit opened (ref_equiv r1' r2' `star` has_struct_field r field r1') (fun _ -> ref_equiv r1' r2' `star` has_struct_field r field r2') @@ -186,10 +218,15 @@ val ghost_struct_field_focus (#v: Ghost.erased (struct_t0 tn n fields)) (r: ref (struct0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) -: STGhostT unit opened + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhostT (squash ( + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + )) opened (has_struct_field r field r' `star` pts_to r v) - (fun _ -> has_struct_field r field r' `star` pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to r' (struct_get_field v field)) + (fun _ -> has_struct_field r field r' `star` pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to r' (Ghost.hide (coerce_eq () (struct_get_field v field)))) val ghost_struct_field (#opened: _) @@ -218,9 +255,28 @@ val struct_field0 t' == fields.fd_type field /\ td' == fields.fd_typedef field }) +: STT (ref td') + (pts_to r v) + (fun r' -> pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to r' (Ghost.hide (coerce_eq () (struct_get_field v field))) `star` has_struct_field r field r') + +inline_for_extraction +[@@noextract_to "krml"] // primitive +let struct_field1 + (#tn: Type0) + (#tf: Type0) + (t': Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (#v: Ghost.erased (struct_t0 tn n fields)) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (td': typedef t') + (sq_t': squash (t' == fields.fd_type field)) + (sq_td': squash (td' == fields.fd_typedef field)) : STT (ref td') (pts_to r v) (fun r' -> pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to r' (struct_get_field v field) `star` has_struct_field r field r') += struct_field0 t' r field td' inline_for_extraction [@@noextract_to "krml"] // primitive let struct_field @@ -231,14 +287,19 @@ let struct_field (#v: Ghost.erased (struct_t0 tn n fields)) (r: ref (struct0 tn n fields)) (field: field_t fields) -: STT (ref #(norm norm_field_steps (fields.fd_type field)) (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (# [ norm_fields () ] sq_t': squash (t' == fields.fd_type field)) + (# [ norm_fields () ] sq_td': squash (td' == fields.fd_typedef field)) + () +: STT (ref td') (pts_to r v) - (fun r' -> pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to #(norm norm_field_steps (fields.fd_type field)) r' (struct_get_field v field) `star` has_struct_field r field r') + (fun r' -> pts_to r (struct_set_field field (unknown (fields.fd_typedef field)) v) `star` pts_to r' (struct_get_field v field) `star` has_struct_field r field r') = struct_field0 - (norm norm_field_steps (fields.fd_type field)) + t' r field - (fields.fd_typedef field) + td' val unstruct_field (#opened: _) @@ -249,15 +310,49 @@ val unstruct_field (#v: Ghost.erased (struct_t0 tn n fields)) (r: ref (struct0 tn n fields)) (field: field_t fields) - (#v': Ghost.erased (fields.fd_type field)) - (r': ref (fields.fd_typedef field)) -: STGhost unit opened + (#t': Type0) + (#td': typedef t') + (#v': Ghost.erased t') + (r': ref td') +: STGhost (Ghost.erased (struct_t0 tn n fields)) opened + (has_struct_field r field r' `star` pts_to r v `star` pts_to r' v') + (fun res -> has_struct_field r field r' `star` pts_to r res) + ( + struct_get_field v field == unknown (fields.fd_typedef field) + ) + (fun res -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + Ghost.reveal res == struct_set_field field (coerce_eq () (Ghost.reveal v')) v + ) + +let unstruct_field_and_drop + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (#v: Ghost.erased (struct_t0 tn n fields)) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (#v': Ghost.erased t') + (r': ref td') +: STGhost (Ghost.erased (struct_t0 tn n fields)) opened (has_struct_field r field r' `star` pts_to r v `star` pts_to r' v') - (fun _ -> has_struct_field r field r' `star` pts_to r (struct_set_field field v' v)) + (fun res -> pts_to r res) ( struct_get_field v field == unknown (fields.fd_typedef field) ) - (fun _ -> True) + (fun res -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + Ghost.reveal res == struct_set_field field (coerce_eq () (Ghost.reveal v')) v + ) += let res = unstruct_field r field r' in + drop (has_struct_field _ _ _); + res let unstruct_field_alt (#opened: _) @@ -279,8 +374,7 @@ let unstruct_field_alt (fun s' -> Ghost.reveal s' == struct_set_field field v' v ) -= unstruct_field r field r'; - _ += unstruct_field r field r' val fractionable_struct (#tn: Type0) diff --git a/lib/steel/c/Steel.ST.C.Types.Union.fsti b/lib/steel/c/Steel.ST.C.Types.Union.fsti index 831b4e15a..21f05f9b7 100644 --- a/lib/steel/c/Steel.ST.C.Types.Union.fsti +++ b/lib/steel/c/Steel.ST.C.Types.Union.fsti @@ -185,9 +185,31 @@ val has_union_field (#fields: field_description_t tf) (r: ref (union0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') : Tot vprop +val has_union_field_prop + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhost unit opened + (has_union_field r field r') + (fun _ -> has_union_field r field r') + True + (fun _ -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + ) + val has_union_field_dup (#opened: _) (#tn: Type0) @@ -196,7 +218,9 @@ val has_union_field_dup (#fields: nonempty_field_description_t tf) (r: ref (union0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') : STGhostT unit opened (has_union_field r field r') (fun _ -> has_union_field r field r' `star` has_union_field r field r') @@ -209,10 +233,15 @@ val has_union_field_inj (#fields: nonempty_field_description_t tf) (r: ref (union0 tn n fields)) (field: field_t fields) - (r1 r2: ref (fields.fd_typedef field)) -: STGhostT unit opened + (#t1: Type0) + (#td1: typedef t1) + (r1: ref td1) + (#t2: Type0) + (#td2: typedef t2) + (r2: ref td2) +: STGhostT (squash (t1 == t2 /\ td1 == td2)) opened (has_union_field r field r1 `star` has_union_field r field r2) - (fun _ -> has_union_field r field r1 `star` has_union_field r field r2 `star` ref_equiv r1 r2) + (fun _ -> has_union_field r field r1 `star` has_union_field r field r2 `star` ref_equiv r1 (coerce_eq () r2)) val has_union_field_equiv_from (#opened: _) @@ -222,7 +251,9 @@ val has_union_field_equiv_from (#fields: nonempty_field_description_t tf) (r1 r2: ref (union0 tn n fields)) (field: field_t fields) - (r': ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r': ref td') : STGhostT unit opened (has_union_field r1 field r' `star` ref_equiv r1 r2) (fun _ -> has_union_field r2 field r' `star` ref_equiv r1 r2) @@ -235,7 +266,9 @@ val has_union_field_equiv_to (#fields: nonempty_field_description_t tf) (r: ref (union0 tn n fields)) (field: field_t fields) - (r1 r2: ref (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (r1 r2: ref td') : STGhostT unit opened (has_union_field r field r1 `star` ref_equiv r1 r2) (fun _ -> has_union_field r field r2 `star` ref_equiv r1 r2) @@ -249,10 +282,15 @@ val ghost_union_field_focus (#v: Ghost.erased (union_t0 tn n fields)) (r: ref (union0 tn n fields)) (field: field_t fields {union_get_case v == Some field}) - (r': ref (fields.fd_typedef field)) -: STGhostT unit opened + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhostT (squash ( + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + )) opened (has_union_field r field r' `star` pts_to r v) - (fun _ -> has_union_field r field r' `star` pts_to r' (union_get_field v field)) + (fun _ -> has_union_field r field r' `star` pts_to r' (Ghost.hide (coerce_eq () (union_get_field v field)))) val ghost_union_field (#opened: _) @@ -281,9 +319,27 @@ val union_field0 t' == fields.fd_type field /\ td' == fields.fd_typedef field }) +: STT (ref td') + (pts_to r v) + (fun r' -> has_union_field r field r' `star` pts_to r' (Ghost.hide (coerce_eq () (union_get_field v field)))) + +inline_for_extraction [@@noextract_to "krml"] +let union_field1 + (#tn: Type0) + (#tf: Type0) + (t': Type0) + (#n: string) + (#fields: field_description_t tf) + (#v: Ghost.erased (union_t0 tn n fields)) + (r: ref (union0 tn n fields)) + (field: field_t fields {union_get_case v == Some field}) + (td': typedef t') + (sq_t': squash (t' == fields.fd_type field)) + (sq_td': squash (td' == fields.fd_typedef field)) : STT (ref td') (pts_to r v) (fun r' -> has_union_field r field r' `star` pts_to r' (union_get_field v field)) += union_field0 t' r field td' inline_for_extraction [@@noextract_to "krml"] // primitive let union_field @@ -294,14 +350,19 @@ let union_field (#v: Ghost.erased (union_t0 tn n fields)) (r: ref (union0 tn n fields)) (field: field_t fields {union_get_case v == Some field}) -: STT (ref #(norm norm_field_steps (fields.fd_type field)) (fields.fd_typedef field)) + (#t': Type0) + (#td': typedef t') + (# [ norm_fields () ] sq_t': squash (t' == fields.fd_type field)) + (# [ norm_fields () ] sq_td': squash (td' == fields.fd_typedef field)) + () +: STT (ref td') (pts_to r v) - (fun r' -> has_union_field r field r' `star` pts_to #(norm norm_field_steps (fields.fd_type field)) r' (union_get_field v field)) + (fun r' -> has_union_field r field r' `star` pts_to r' (union_get_field v field)) = union_field0 - (norm norm_field_steps (fields.fd_type field)) + t' r field - (fields.fd_typedef field) + td' val ununion_field (#opened: _) @@ -311,11 +372,44 @@ val ununion_field (#fields: field_description_t tf) (r: ref (union0 tn n fields)) (field: field_t fields) - (#v': Ghost.erased (fields.fd_type field)) - (r': ref (fields.fd_typedef field)) -: STGhostT unit opened + (#t': Type0) + (#td': typedef t') + (#v': Ghost.erased t') + (r': ref td') +: STGhost (Ghost.erased (union_t0 tn n fields)) opened (has_union_field r field r' `star` pts_to r' v') - (fun _ -> has_union_field r field r' `star` pts_to r (union_set_field tn n fields field v')) + (fun res -> has_union_field r field r' `star` pts_to r res) + True + (fun res -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + Ghost.reveal res == union_set_field tn n fields field (coerce_eq () (Ghost.reveal v')) + ) + +let ununion_field_and_drop + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (#v': Ghost.erased t') + (r': ref td') +: STGhost (Ghost.erased (union_t0 tn n fields)) opened + (has_union_field r field r' `star` pts_to r' v') + (fun res -> pts_to r res) + True + (fun res -> + t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + Ghost.reveal res == union_set_field tn n fields field (coerce_eq () (Ghost.reveal v')) + ) += let res = ununion_field r field r' in + drop (has_union_field _ _ _); + res // NOTE: we DO NOT support preservation of struct prefixes @@ -335,10 +429,30 @@ val union_switch_field0 }) : ST (ref td') // need to write the pcm carrier value, so this cannot be Ghost or Atomic (pts_to r v) - (fun r' -> has_union_field r field r' `star` pts_to r' (uninitialized (fields.fd_typedef field))) + (fun r' -> has_union_field r field r' `star` pts_to r' (uninitialized td')) (full (union0 tn n fields) v) (fun r' -> True) +inline_for_extraction [@@noextract_to "krml"] +let union_switch_field1 + (#tn: Type0) + (#tf: Type0) + (t': Type0) + (#n: string) + (#fields: field_description_t tf) + (#v: Ghost.erased (union_t0 tn n fields)) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (td': typedef t') + (sq_t': squash (t' == fields.fd_type field)) + (sq_td': squash (td' == fields.fd_typedef field)) +: ST (ref td') // need to write the pcm carrier value, so this cannot be Ghost or Atomic + (pts_to r v) + (fun r' -> has_union_field r field r' `star` pts_to r' (uninitialized td')) + (full (union0 tn n fields) v) + (fun r' -> True) += union_switch_field0 t' r field td' + inline_for_extraction [@@noextract_to "krml"] let union_switch_field (#tn: Type0) @@ -348,13 +462,18 @@ let union_switch_field (#v: Ghost.erased (union_t0 tn n fields)) (r: ref (union0 tn n fields)) (field: field_t fields) -: ST (ref #(norm norm_field_steps (fields.fd_type field)) (fields.fd_typedef field)) // need to write the pcm carrier value, so this cannot be Ghost or Atomic + (#t': Type0) + (#td': typedef t') + (# [ norm_fields () ] sq_t': squash (t' == fields.fd_type field)) + (# [ norm_fields () ] sq_td': squash (td' == fields.fd_typedef field)) + () +: ST (ref td') // need to write the pcm carrier value, so this cannot be Ghost or Atomic (pts_to r v) - (fun r' -> has_union_field r field r' `star` pts_to #(norm norm_field_steps (fields.fd_type field)) r' (uninitialized (fields.fd_typedef field))) + (fun r' -> has_union_field r field r' `star` pts_to r' (uninitialized td')) (full (union0 tn n fields) v) (fun r' -> True) = union_switch_field0 - (norm norm_field_steps (fields.fd_type field)) + t' r field - (fields.fd_typedef field) + td' diff --git a/lib/steel/pulse/Pulse.Checker.Abs.fst b/lib/steel/pulse/Pulse.Checker.Abs.fst index eda480110..25837300d 100644 --- a/lib/steel/pulse/Pulse.Checker.Abs.fst +++ b/lib/steel/pulse/Pulse.Checker.Abs.fst @@ -64,7 +64,8 @@ let rec check_abs let pre_opened, ret_ty, post_hint_body = match c with | C_Tot _ -> - fail g (Some body.range) "Tm_Abs in case of st term, C_Tot annotation" + fail g (Some body.range) + "Unexpected error: found a total computation annotation on a top-level function" | _ -> open_term_nv (comp_pre c) px, @@ -75,7 +76,7 @@ let rec check_abs let pre = close_term pre_opened x in let post : post_hint_opt g' = match post_hint_body with - | None -> fail g (Some body.range) "Tm_Abs without a post hint, bailing" + | None -> fail g (Some body.range) "Top-level functions must be annotated with pre and post conditions" | Some post -> let post_hint_typing : post_hint_t @@ -84,9 +85,10 @@ let rec check_abs Some post_hint_typing in - let r = check g' pre_opened pre_typing post body_opened in + let ppname = mk_ppname_no_range "_fret" in + let r = check g' pre_opened pre_typing post ppname body_opened in let (| body, c_body, body_typing |) : st_typing_in_ctxt g' pre_opened post = - apply_checker_result_k #_ #_ #(Some?.v post) r in + apply_checker_result_k #_ #_ #(Some?.v post) r ppname in check_effect_annotation g' body.range c c_body; diff --git a/lib/steel/pulse/Pulse.Checker.Abs.fst.hints b/lib/steel/pulse/Pulse.Checker.Abs.fst.hints index af115cb5a..bc25947d6 100644 --- a/lib/steel/pulse/Pulse.Checker.Abs.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Abs.fst.hints @@ -1,5 +1,5 @@ [ - "tn9UL\u001fZc\u001e\u000e>", + "jR\u0005h\u0004*ۓz", [ [ "Pulse.Checker.Abs.check_effect_annotation", @@ -13,7 +13,7 @@ "string_typing" ], 0, - "35e023a0fc1fe95626112d8357759639" + "e3ed564cdb21aa89d1f311e001c5aa9a" ], [ "Pulse.Checker.Abs.check_abs", @@ -48,6 +48,7 @@ "equation_FStar.Sealed.Inhabited.sealed", "equation_FStar.Sealed.Inhabited.sealed_", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Pure.push_context", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.index", "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.ppname_default", @@ -115,6 +116,7 @@ "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_6c182d6f9819de8b46a7a4d39f909d33", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", @@ -136,7 +138,7 @@ "typing_Pulse.Typing.Env.push_binding" ], 0, - "85aa26bf0c11aef9fef5b754dfc2e923" + "b392d6b9fe11f6e3b5eb6649a0773099" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Admit.fst b/lib/steel/pulse/Pulse.Checker.Admit.fst index 740c16841..663ca88b4 100644 --- a/lib/steel/pulse/Pulse.Checker.Admit.fst +++ b/lib/steel/pulse/Pulse.Checker.Admit.fst @@ -8,6 +8,8 @@ open Pulse.Checker.Pure open Pulse.Checker.Base open Pulse.Checker.Prover +module P = Pulse.Syntax.Printer + let post_hint_compatible (p:option post_hint_t) (x:var) (t:term) (u:universe) (post:vprop) = match p with | None -> True @@ -21,10 +23,13 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_Admit? t.term }) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_admit" t.range in + let Tm_Admit { ctag = c; typ=t; post } = t.term in let x = fresh g in @@ -36,9 +41,14 @@ let check post:vprop { post_hint_compatible post_hint x t u post } & tot_typing (push_binding g x (fst px) t) post tm_vprop) = match post, post_hint with - | None, None - | Some _, Some _ -> - fail g None "T_Admit: either no post or two posts" + | None, None -> + fail g None "could not find a post annotation on admit, please add one" + + | Some post1, Some post2 -> + fail g None + (Printf.sprintf "found two post annotations on admit: %s and %s, please remove one" + (P.term_to_string post1) + (P.term_to_string post2.post)) | Some post, _ -> let (| u, t_typing |) = check_universe g t in @@ -51,7 +61,7 @@ let check | _, Some post -> let post : post_hint_t = post in if x `Set.mem` freevars post.post - then fail g None "Unexpected freevar clash in Tm_Admit" + then fail g None "Impossible: unexpected freevar clash in Tm_Admit, please file a bug-report" else ( let post_typing_rec = post_hint_typing g post x in let post_opened = open_term_nv post.post px in @@ -65,4 +75,4 @@ let check assume (open_term (close_term post_opened x) x == post_opened); let d = T_Admit _ _ c (STC _ s x t_typing pre_typing post_typing) in - repack (try_frame_pre pre_typing d) post_hint t.range + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint t.range diff --git a/lib/steel/pulse/Pulse.Checker.Admit.fst.hints b/lib/steel/pulse/Pulse.Checker.Admit.fst.hints index 25390f9bc..f3ef21dcb 100644 --- a/lib/steel/pulse/Pulse.Checker.Admit.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Admit.fst.hints @@ -1,5 +1,5 @@ [ - "Lzp\u007f0\r|kȲ\u001f", + "\u007fO`\u0011Z#", [ [ "Pulse.Checker.Admit.post_hint_compatible", @@ -11,7 +11,7 @@ "lemma_FStar.Pervasives.invertOption" ], 0, - "3bd7c950f7ea9004a5f6eec1ac143e79" + "47e3c39481aa9899af8f9bc13b9d21f1" ], [ "Pulse.Checker.Admit.check", @@ -24,6 +24,8 @@ "@fuel_irrelevance_Pulse.Syntax.Naming.freevars.fuel_instrumented", "@query", "FStar.Pervasives.Native_pretyping_b53dbd183c526bc5d0f20d7b966ae125", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", @@ -33,6 +35,8 @@ "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", "constructor_distinct_Pulse.Syntax.Base.STT", + "constructor_distinct_Pulse.Syntax.Base.STT_Atomic", + "constructor_distinct_Pulse.Syntax.Base.STT_Ghost", "constructor_distinct_Pulse.Syntax.Base.Tm_Admit", "data_elim_Pulse.Typing.Mkpost_hint_t", "disc_equation_FStar.Pervasives.Native.None", @@ -45,22 +49,19 @@ "equation_Pulse.Checker.Admit.post_hint_compatible", "equation_Pulse.Syntax.Base.index", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.v_as_nv", - "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Syntax.Naming.close_term", "equation_Pulse.Syntax.Naming.open_term", "equation_Pulse.Syntax.Pure.tm_type", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.FV.set_minus", "equation_Pulse.Typing.comp_admit", "equation_Pulse.Typing.fresh_wrt", - "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.ctag", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "fuel_guarded_inversion_Pulse.Typing.post_hint_t", "function_token_typing_Prims.__cache_version_number__", @@ -82,7 +83,6 @@ "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", "proj_equation_Pulse.Syntax.Base.Mkst_comp_u", - "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "proj_equation_Pulse.Typing.Mkpost_hint_t_post", "proj_equation_Pulse.Typing.Mkpost_hint_t_ret_ty", "proj_equation_Pulse.Typing.Mkpost_hint_t_u", @@ -107,23 +107,27 @@ "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_u", "projection_inverse_Pulse.Syntax.Base.Tm_Admit__0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_717807cab8f2d0ea552aff3c667b3f67", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", "refinement_interpretation_Tm_refine_ecc02256d87cc95183f37fc512700b64", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", "token_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", "typing_FStar.Pervasives.Native.uu___is_None", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.complement", "typing_FStar.Set.mem", "typing_FStar.Set.singleton", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Naming.close_term", "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env" + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context" ], 0, - "aa5544803dcd5a35cb45892a02c3e128" + "3089e3801a376cde2895ac975287e48a" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Admit.fsti b/lib/steel/pulse/Pulse.Checker.Admit.fsti index 6c2953707..278fee368 100644 --- a/lib/steel/pulse/Pulse.Checker.Admit.fsti +++ b/lib/steel/pulse/Pulse.Checker.Admit.fsti @@ -11,5 +11,6 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_Admit? t.term }) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Admit.fsti.hints b/lib/steel/pulse/Pulse.Checker.Admit.fsti.hints index ad5209db6..1e7b972f3 100644 --- a/lib/steel/pulse/Pulse.Checker.Admit.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Admit.fsti.hints @@ -1 +1 @@ -[ "A\r\u001e let {sort; ppname} = R.inspect_binder b in - let sort = option_must (readback_ty sort) "Failed to readback elaborated binder in peel_off" in + let sort = option_must (readback_ty sort) + (Printf.sprintf "Failed to readback elaborated binder sort %s in refl_abs_binders" + (T.term_to_string sort)) in refl_abs_binders body ({ binder_ty = sort; binder_ppname = mk_ppname ppname (RU.range_of_term t) }::acc) | _ -> L.rev acc @@ -44,7 +46,9 @@ let infer_binder_types (g:env) (bs:list binder) (v:vprop) | _ -> let tv = elab_term v in if not (is_host_term tv) - then fail g (Some v.range) (Printf.sprintf "Cannot infer type of %s" (P.term_to_string v)); + then fail g (Some v.range) + (Printf.sprintf "assert.infer_binder_types: elaborated %s to %s, which failed the host term check" + (P.term_to_string v) (T.term_to_string tv)); let as_binder (b:binder) : R.binder = let open R in let bv : binder_view = @@ -65,7 +69,7 @@ let infer_binder_types (g:env) (bs:list binder) (v:vprop) let inst_abstraction, _ = PC.instantiate_term_implicits g (tm_fstar abstraction v.range) in match inst_abstraction.t with | Tm_FStar t -> refl_abs_binders t [] - | _ -> T.fail "Impossible: Instantiated abstraction is not embedded F* term" + | _ -> T.fail "Impossible: instantiated abstraction is not embedded F* term, please file a bug-report" let rec open_binders (g:env) (bs:list binder) (uvs:env { disjoint uvs g }) (v:term) (body:st_term) : T.Tac (uvs:env { disjoint uvs g } & term & st_term) = @@ -106,13 +110,16 @@ let unfold_defs (g:env) (defs:option (list string)) (t:term) | None -> [] in let rt = RU.unfold_def (fstar_env g) head fully t in - let rt = option_must rt "Unexpected: reduction produced an ill-formed term" in - let ty = option_must (readback_ty rt) "Unexpected: unable to readback unfolded term" in + let rt = option_must rt + (Printf.sprintf "unfolding %s returned None" (T.term_to_string t)) in + let ty = option_must (readback_ty rt) + (Printf.sprintf "error in reading back the unfolded term %s" (T.term_to_string rt)) in debug_log g (fun _ -> Printf.sprintf "Unfolded %s to F* term %s and readback as %s" (T.term_to_string t) (T.term_to_string rt) (P.term_to_string ty)); ty ) | _ -> - fail g (Some (RU.range_of_term t)) (Printf.sprintf "Cannot unfold %s" (T.term_to_string t)) + fail g (Some (RU.range_of_term t)) + (Printf.sprintf "Cannot unfold %s, the head is not an fvar" (T.term_to_string t)) let check_unfoldable g (v:term) : T.Tac unit = match v.t with @@ -129,11 +136,14 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { Tm_ProofHintWithBinders? st.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) = + let g = push_context g "check_assert" st.range in + let Tm_ProofHintWithBinders { hint_type; binders=bs; v; t=body } = st.term in let bs = infer_binder_types g bs v in @@ -146,7 +156,7 @@ let check let (| v, d |) = PC.check_vprop (push_env g uvs) v in let (| g1, nts, pre', k_frame |) = Prover.prove pre_typing uvs d in let (| x, x_ty, pre'', g2, k |) = - check g1 (tm_star (PS.nt_subst_term v nts) pre') (magic ()) post_hint (PS.nt_subst_st_term body nts) in + check g1 (tm_star (PS.nt_subst_term v nts) pre') (magic ()) post_hint res_ppname (PS.nt_subst_st_term body nts) in (| x, x_ty, pre'', g2, k_elab_trans k_frame k |) | _ -> @@ -178,4 +188,4 @@ let check v = lhs; t = st }; range = st.range } in - check g pre pre_typing post_hint st + check g pre pre_typing post_hint res_ppname st diff --git a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fst.hints b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fst.hints index d3885957c..d705214f7 100644 --- a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fst.hints @@ -1,5 +1,5 @@ [ - "*-\u001bՒC\u0013)\b>\u001f\u001d", + "v5_<%w[", [ [ "Pulse.Checker.AssertWithBinders.option_must", @@ -8,7 +8,7 @@ 1, [ "@query", "lemma_FStar.Pervasives.invertOption" ], 0, - "ebb3e7478db6b3278a09d981bf96431c" + "223601c56f746132bd21e5bdb42bfa1b" ], [ "Pulse.Checker.AssertWithBinders.refl_abs_binders", @@ -18,12 +18,20 @@ [ "@MaxIFuel_assumption", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "constructor_distinct_FStar.Tactics.Result.Failed", + "constructor_distinct_FStar.Tactics.Result.Success", "equation_FStar.Sealed.Inhabited.is_sealed", "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "string_typing", "true_interp" + "projection_inverse_FStar.Tactics.Result.Failed_a", + "projection_inverse_FStar.Tactics.Result.Failed_exn", + "projection_inverse_FStar.Tactics.Result.Failed_ps", + "projection_inverse_FStar.Tactics.Result.Success_a", + "projection_inverse_FStar.Tactics.Result.Success_ps", + "projection_inverse_FStar.Tactics.Result.Success_v", "string_typing", + "true_interp" ], 0, - "0adc76f14300d9b954fe51db69b64517" + "15b3120f0dc57ee5bfead3be7616d0e5" ], [ "Pulse.Checker.AssertWithBinders.infer_binder_types", @@ -78,7 +86,7 @@ "typing_tok_FStar.Reflection.V2.Data.Q_Explicit@tok" ], 0, - "3ecd2bec4058f5b9a86f8173732126c2" + "c1aedee9309bebe7c96b357c0b495da1" ], [ "Pulse.Checker.AssertWithBinders.open_binders", @@ -134,7 +142,7 @@ "typing_Pulse.Typing.Env.fstar_env" ], 0, - "a1f922564db0ab0d5f5d0ee635b838f7" + "a0c40b167498c1b0be38918dff6b69a2" ], [ "Pulse.Checker.AssertWithBinders.close_binders", @@ -157,12 +165,18 @@ [ "@MaxIFuel_assumption", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "constructor_distinct_FStar.Pervasives.Native.None", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_FStar.Tactics.Result.Failed", "constructor_distinct_FStar.Tactics.Result.Success", "equation_Prims.eqtype", "equation_Pulse.Syntax.Base.range_singleton_trigger", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "function_token_typing_Prims.string", "kinding_Prims.list@tok", "lemma_FStar.Pervasives.invertOption", + "projection_inverse_FStar.Tactics.Result.Failed_a", + "projection_inverse_FStar.Tactics.Result.Failed_exn", + "projection_inverse_FStar.Tactics.Result.Failed_ps", "projection_inverse_FStar.Tactics.Result.Success_a", "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", @@ -170,7 +184,7 @@ "string_typing" ], 0, - "1a62ee8ce2a47156dcb65222bb5458ab" + "f09e54dd66c1f55c55a09afb285920cb" ], [ "Pulse.Checker.AssertWithBinders.check_unfoldable", @@ -214,19 +228,20 @@ "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", "equation_Pulse.Syntax.Base.not_tv_unknown", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.proof_hint_type", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.__cache_version_number__", - "int_inversion", "kinding_Pulse.Typing.post_hint_t@tok", + "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Pervasives.invertOption", "lemma_FStar.Reflection.Typing.inspect_pack", "lemma_FStar.Set.lemma_equal_elim", @@ -235,6 +250,7 @@ "lemma_Pulse.Typing.Env.env_extends_trans", "lemma_Pulse.Typing.Env.mk_env_dom", "primitive_Prims.op_AmpAmp", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Prims.Mkdtuple2__1", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Tactics.Result.Failed_a", @@ -244,22 +260,26 @@ "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Pulse.Syntax.Base.Tm_ProofHintWithBinders__0", - "refinement_interpretation_Tm_refine_0e7cec6ed8f6e8567fd60faa69f1ee6b", + "refinement_interpretation_Tm_refine_22829e142fee025de3f65b2dd8597285", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", + "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", "refinement_interpretation_Tm_refine_bf49085558242af8c310020a9c32bdc7", + "refinement_interpretation_Tm_refine_c368f222d3b510422f50624ef34643bf", "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", "typing_FStar.Map.domain", "typing_FStar.Reflection.Typing.unit_fv", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.mk_env", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "a56a99ca49f6a093f034d5d278aadf37" + "c6f591576fce77169b45becce2f77642" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti index be699b46b..5666efc45 100644 --- a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti +++ b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { Tm_ProofHintWithBinders? st.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti.hints b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti.hints index e5044b2e7..060b3e4e7 100644 --- a/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.AssertWithBinders.fsti.hints @@ -1 +1 @@ -[ "\u001d,-\b\u001dmU\u0015w", [] ] \ No newline at end of file +[ ",rf5\u0017H\u0010,K", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Base.fst b/lib/steel/pulse/Pulse.Checker.Base.fst index 156c7cd1d..83ed9e62e 100644 --- a/lib/steel/pulse/Pulse.Checker.Base.fst +++ b/lib/steel/pulse/Pulse.Checker.Base.fst @@ -137,15 +137,13 @@ let k_elab_equiv_continutation (#g1:env) (#g2:env { g2 `env_extends` g1 }) (#ctx (| tm_emp, emp_typing, d |) in let (| st, c, st_d |) = res in - if not (stateful_comp c) then k post_hint (| st, c, st_d |) - else - let (| _, pre_typing, _, _ |) = - Metatheory.(st_comp_typing_inversion (comp_typing_inversion (st_typing_correctness st_d))) in - let (| c', st_d' |) = - apply_frame (vprop_equiv_typing_bk pre_typing d) st_d framing_token in - assert (comp_post c' == tm_star (comp_post c) tm_emp); - let st_d' = simplify_post st_d' (comp_post c) in - k post_hint (| st, _, st_d' |) + let (| _, pre_typing, _, _ |) = + Metatheory.(st_comp_typing_inversion (comp_typing_inversion (st_typing_correctness st_d))) in + let (| c', st_d' |) = + apply_frame (vprop_equiv_typing_bk pre_typing d) st_d framing_token in + assert (comp_post c' == tm_star (comp_post c) tm_emp); + let st_d' = simplify_post st_d' (comp_post c) in + k post_hint (| st, _, st_d' |) #pop-options let vprop_equiv_typing_fwd (#g:env) (#ctxt:_) (ctxt_typing:tot_typing g ctxt tm_vprop) @@ -167,19 +165,18 @@ let k_elab_equiv_prefix in let res = k post_hint res in let (| st, c, st_d |) = res in - if not (stateful_comp c) then (| st, c, st_d |) - else let (| _, pre_typing, _, _ |) = - Metatheory.(st_comp_typing_inversion (comp_typing_inversion (st_typing_correctness st_d))) in - let (| c', st_d' |) = - apply_frame - (vprop_equiv_typing_fwd pre_typing d) - st_d - framing_token in - simplify_lemma c c' post_hint; - let c'' = comp_st_with_post c' (comp_post c) in - let st_d' : st_typing g1 st c'' = simplify_post st_d' (comp_post c) in - let res : st_typing_in_ctxt g1 ctxt2 post_hint = (| st, c'', st_d' |) in - res + let (| _, pre_typing, _, _ |) = + Metatheory.(st_comp_typing_inversion (comp_typing_inversion (st_typing_correctness st_d))) in + let (| c', st_d' |) = + apply_frame + (vprop_equiv_typing_fwd pre_typing d) + st_d + framing_token in + simplify_lemma c c' post_hint; + let c'' = comp_st_with_post c' (comp_post c) in + let st_d' : st_typing g1 st c'' = simplify_post st_d' (comp_post c) in + let res : st_typing_in_ctxt g1 ctxt2 post_hint = (| st, c'', st_d' |) in + res #pop-options let k_elab_equiv @@ -201,10 +198,12 @@ let continuation_elaborator_with_bind (#g:env) (ctxt:term) (#e1:st_term) (e1_typing:st_typing g e1 c1) (ctxt_pre1_typing:tot_typing g (tm_star ctxt (comp_pre c1)) tm_vprop) - (x:var { None? (lookup g x) }) + (x:nvar { None? (lookup g (snd x)) }) : T.Tac (continuation_elaborator - g (tm_star ctxt (comp_pre c1)) - (push_binding g x ppname_default (comp_res c1)) (tm_star (open_term (comp_post c1) x) ctxt)) = + g + (tm_star ctxt (comp_pre c1)) + (push_binding g (snd x) (fst x) (comp_res c1)) + (tm_star (open_term (comp_post c1) (snd x)) ctxt)) = let pre1 = comp_pre c1 in let res1 = comp_res c1 in @@ -220,45 +219,41 @@ let continuation_elaborator_with_bind (#g:env) (ctxt:term) let (| u_of_1, pre_typing, _, _ |) = Metatheory.(st_comp_typing_inversion (comp_typing_inversion (st_typing_correctness e1_typing))) in let b = res1 in - let g' = push_binding g x ppname_default b in + let ppname, x = x in + let g' = push_binding g x ppname b in let post1_opened = open_term_nv post1 (v_as_nv x) in let k : continuation_elaborator g (tm_star ctxt pre1) g' (tm_star post1_opened ctxt) = fun post_hint res -> let (| e2, c2, e2_typing |) = res in - if not (stateful_comp c2) // || None? post_hint - then T.fail "Unexpected non-stateful comp in continuation elaborate" + let e2_typing : st_typing g' e2 c2 = e2_typing in + let e2_closed = close_st_term e2 x in + assume (open_st_term e2_closed x == e2); + assert (comp_pre c1 == (tm_star ctxt pre1)); + assert (comp_post c1 == tm_star post1 ctxt); + assert (comp_pre c2 == tm_star post1_opened ctxt); + assert (open_term (comp_post c1) x == tm_star post1_opened (open_term ctxt x)); + // ctxt is well-typed, hence ln + assume (open_term ctxt x == ctxt); + assert (open_term (comp_post c1) x == comp_pre c2); + // we closed e2 with x + assume (~ (x `Set.mem` freevars_st e2_closed)); + if x `Set.mem` freevars (comp_post c2) + then fail g' None "Impossible: freevar clash when constructing continuation elaborator for bind, please file a bug-report" else ( - let e2_typing : st_typing g' e2 c2 = e2_typing in - let e2_closed = close_st_term e2 x in - assume (open_st_term e2_closed x == e2); - assert (comp_pre c1 == (tm_star ctxt pre1)); - assert (comp_post c1 == tm_star post1 ctxt); - assert (comp_pre c2 == tm_star post1_opened ctxt); - assert (open_term (comp_post c1) x == tm_star post1_opened (open_term ctxt x)); - // ctxt is well-typed, hence ln - assume (open_term ctxt x == ctxt); - assert (open_term (comp_post c1) x == comp_pre c2); - // we closed e2 with x - assume (~ (x `Set.mem` freevars_st e2_closed)); - if x `Set.mem` freevars (comp_post c2) - then T.fail "Impossible" - else ( - let t_typing, post_typing = - Pulse.Typing.Combinators.bind_res_and_post_typing g (st_comp_of_comp c2) x post_hint in - let (| e, c, e_typing |) = - Pulse.Typing.Combinators.mk_bind - g (tm_star ctxt pre1) - e1 e2_closed c1 c2 (v_as_nv x) e1_typing - u_of_1 - e2_typing - t_typing - post_typing - in - (| e, c, e_typing |) - ) + let t_typing, post_typing = + Pulse.Typing.Combinators.bind_res_and_post_typing g (st_comp_of_comp c2) x post_hint in + let (| e, c, e_typing |) = + Pulse.Typing.Combinators.mk_bind + g (tm_star ctxt pre1) + e1 e2_closed c1 c2 (ppname, x) e1_typing + u_of_1 + e2_typing + t_typing + post_typing + in + (| e, c, e_typing |) ) - in k #pop-options @@ -270,16 +265,14 @@ let continuation_elaborator_with_tot_bind (#g:env) (#ctxt:term) (#e1:term) (#t1:term) (e1_typing:tot_typing g e1 t1) - (x:var { None? (lookup g x) }) + (x:nvar { None? (lookup g (snd x)) }) : T.Tac (continuation_elaborator g ctxt - (push_binding g x ppname_default t1) ctxt) = + (push_binding g (snd x) (fst x) t1) ctxt) = + assert ((push_binding g (snd x) (fst x) t1) `env_extends` g); fun post_hint (| e2, c2, d2 |) -> - - if not (stateful_comp c2) - then fail g (Some e2.range) "Tm_TotBind: e2 is not a stateful computation"; - + let ppname, x = x in let e2_closed = close_st_term e2 x in assume (open_st_term (close_st_term e2 x) x == e2); @@ -289,6 +282,7 @@ let continuation_elaborator_with_tot_bind (#g:env) (#ctxt:term) assume (~ (x `Set.mem` freevars_st e2_closed)); let d : st_typing g e c = T_TotBind g e1 e2_closed t1 c2 x e1_typing d2 in + let _ = match post_hint with | None -> () @@ -348,16 +342,16 @@ let intro_comp_typing (g:env) let stc = intro_st_comp_typing st in let (| ty, i_typing |) = CP.core_check_term g i in if not (eq_tm ty tm_inames) - then fail g None "Ill-typed inames" + then fail g None (Printf.sprintf "ill-typed inames term %s" (P.term_to_string i)) else CT_STAtomic _ _ _ (E i_typing) stc | C_STGhost i st -> let stc = intro_st_comp_typing st in let (| ty, i_typing |) = CP.core_check_term g i in if not (eq_tm ty tm_inames) - then fail g None "Ill-typed inames" + then fail g None (Printf.sprintf "ill-typed inames term %s" (P.term_to_string i)) else CT_STGhost _ _ _ (E i_typing) stc -let return_in_ctxt (g:env) (y:var) (u:universe) (ty:term) (ctxt:vprop) +let return_in_ctxt (g:env) (y:var) (y_ppname:ppname) (u:universe) (ty:term) (ctxt:vprop) (ty_typing:universe_of g ty u) (post_hint0:post_hint_opt g { Some? post_hint0 /\ checker_res_matches_post_hint g post_hint0 y ty ctxt}) @@ -373,12 +367,13 @@ let return_in_ctxt (g:env) (y:var) (u:universe) (ty:term) (ctxt:vprop) match post_hint.ctag_hint with | None -> STT | Some ctag -> ctag in - let d = T_Return g ctag false u ty (null_var y) post_hint.post x ty_typing + let y_tm = tm_var {nm_index=y;nm_ppname=y_ppname} in + let d = T_Return g ctag false u ty y_tm post_hint.post x ty_typing (magic ()) // that null_var y is well typed at ty in g, we know since lookup g y == Some ty (magic ()) // typing of (open post x) in (g, x) ... post_hint is well-typed, so should get in - let t = wr (Tm_Return {ctag=ctag;insert_eq=false;term=null_var y}) in - let c = comp_return ctag false u ty (null_var y) post_hint.post x in + let t = wr (Tm_Return {ctag=ctag;insert_eq=false;term=y_tm}) in + let c = comp_return ctag false u ty y_tm post_hint.post x in let d : st_typing g t c = d in let _ :squash (comp_pre c == ctxt /\ comp_post_matches_hint c (Some post_hint)) = @@ -391,38 +386,36 @@ let return_in_ctxt (g:env) (y:var) (u:universe) (ty:term) (ctxt:vprop) let apply_checker_result_k (#g:env) (#ctxt:vprop) (#post_hint:post_hint_for_env g) (r:checker_result_t g ctxt (Some post_hint)) + (res_ppname:ppname) : T.Tac (st_typing_in_ctxt g ctxt (Some post_hint)) = // TODO: FIXME add to checker result type? - let (| y, ty_y, pre', g1, k |) = r in + let (| y, g1, (| u_ty, ty_y, d_ty_y |), (| pre', _ |), k |) = r in let (| u_ty_y, d_ty_y |) = Pulse.Checker.Pure.check_universe g1 ty_y in let d : st_typing_in_ctxt g1 pre' (Some post_hint) = - return_in_ctxt g1 y u_ty_y ty_y pre' d_ty_y (Some post_hint) in + return_in_ctxt g1 y res_ppname u_ty_y ty_y pre' d_ty_y (Some post_hint) in k (Some post_hint) d #push-options "--z3rlimit_factor 2 --fuel 0 --ifuel 1" let checker_result_for_st_typing (#g:env) (#ctxt:vprop) (#post_hint:post_hint_opt g) (d:st_typing_in_ctxt g ctxt post_hint) + (ppname:ppname) : T.Tac (checker_result_t g ctxt post_hint) = let (| t, c, d |) = d in - if not (stateful_comp c) - then fail g None "checker_result_for_st_typing: not a stateful comp"; - - let x = fresh g in - let g' = push_binding g x ppname_default (comp_res c) in - let ctxt' = open_term_nv (comp_post c) (ppname_default, x) in + let g' = push_binding g x ppname (comp_res c) in + let ctxt' = open_term_nv (comp_post c) (ppname, x) in let k : continuation_elaborator g (tm_star tm_emp (comp_pre c)) g' (tm_star ctxt' tm_emp) = - continuation_elaborator_with_bind tm_emp d (magic ()) x in + continuation_elaborator_with_bind tm_emp d (magic ()) (ppname, x) in let k : continuation_elaborator g (comp_pre c) g' ctxt' = k_elab_equiv k (magic ()) (magic ()) in @@ -434,5 +427,12 @@ let checker_result_for_st_typing (#g:env) (#ctxt:vprop) (#post_hint:post_hint_op assert (g' `env_extends` g); - (| x, comp_res c, ctxt', g', k |) + let comp_res_typing, _, f = + Metatheory.(st_comp_typing_inversion_cofinite (comp_typing_inversion (st_typing_correctness d))) in + + // magic is the typing of comp_res in g' + // weaken comp_res_typing + + assume (~ (x `Set.mem` freevars (comp_post c))); + (| x, g', (| comp_u c, comp_res c, magic () |), (| ctxt', f x |), k |) #pop-options diff --git a/lib/steel/pulse/Pulse.Checker.Base.fst.hints b/lib/steel/pulse/Pulse.Checker.Base.fst.hints index bac1b1efa..87c12cbba 100644 --- a/lib/steel/pulse/Pulse.Checker.Base.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Base.fst.hints @@ -1,5 +1,5 @@ [ - ")\u001dW<7J", + "\u0017`>\u001f-P", [ [ "Pulse.Checker.Base.format_failed_goal", @@ -13,7 +13,7 @@ "string_typing" ], 0, - "6b19a506d84d9a5994583a7066200480" + "7b55850046123a505cc420fbef018e09" ], [ "Pulse.Checker.Base.post_typing_as_abstraction", @@ -132,7 +132,7 @@ "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Pure.tm_type", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.Metatheory.comp_typing_u", + "equation_Pulse.Typing.Metatheory.Base.comp_typing_u", "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.tot_typing", "equation_Pulse.Typing.typing", @@ -142,7 +142,6 @@ "fuel_guarded_inversion_Pulse.Typing.comp_typing", "fuel_guarded_inversion_Pulse.Typing.my_erased", "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", - "interpretation_Tm_abs_9627aa63c90056f8b614da4dfb4d20bf", "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", @@ -164,10 +163,10 @@ "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion" + "typing_Pulse.Typing.Metatheory.Base.st_comp_typing_inversion" ], 0, - "fdd87d969318be1c8033449b5c1ffa41" + "bb1b3a3bc195ade1e5e289848661c929" ], [ "Pulse.Checker.Base.continuation_elaborator", @@ -190,7 +189,7 @@ "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "ae3fa735230c64739b7f3e917bfa2388" + "3c4994ca809c789b05eca23ccaf9e899" ], [ "Pulse.Checker.Base.k_elab_unit", @@ -315,7 +314,7 @@ "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "829db89f9fb8de08d25d1707c541fbc9" + "c295c928c458d9a7b282e53af985a061" ], [ "Pulse.Checker.Base.st_equiv_post", @@ -350,20 +349,16 @@ "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Naming.open_term", - "equation_Pulse.Syntax.Pure.tm_type", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.st_equiv_pre", - "equation_Pulse.Typing.tot_typing", "equation_Pulse.Typing.typing", "equation_Pulse.Typing.universe_of", "fuel_guarded_inversion_FStar.Pervasives.dtuple4", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", - "fuel_guarded_inversion_Pulse.Typing.my_erased", "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", "interpretation_Tm_abs_9627aa63c90056f8b614da4dfb4d20bf", - "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", @@ -388,18 +383,16 @@ "refinement_interpretation_Tm_refine_36441f5163bf4613efd69bece0701f67", "refinement_interpretation_Tm_refine_6262a74a3e7906640b3d8d4146589509", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.stateful_comp", "typing_Pulse.Syntax.Base.uu___is_C_Tot", "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Metatheory.comp_typing_inversion", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion", - "typing_Pulse.Typing.Metatheory.st_typing_correctness" + "typing_Pulse.Typing.Metatheory.Base.comp_typing_inversion", + "typing_Pulse.Typing.Metatheory.Base.st_typing_correctness" ], 0, - "a11f650c27a5fa90523e1d606454f364" + "c374d83917f9bf663aa69365963013f6" ], [ "Pulse.Checker.Base.simplify_post", @@ -419,7 +412,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "8839f843d9fb31dce7c84f453e5b98df" + "a397b854a17ecfe0cdaf3a0350187aaa" ], [ "Pulse.Checker.Base.simplify_post", @@ -558,14 +551,15 @@ 0, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", "bool_typing", + "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", + "constructor_distinct_Pulse.Syntax.Base.C_Tot", "data_elim_FStar.Pervasives.Mkdtuple3", "data_elim_FStar.Pervasives.Native.Some", - "data_elim_Prims.Mkdtuple2", "data_elim_Pulse.Syntax.Base.Mkst_comp", + "data_elim_Prims.Mkdtuple2", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_FStar.Pervasives.Native.Some", "disc_equation_Pulse.Syntax.Base.C_ST", @@ -590,29 +584,27 @@ "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Metatheory.Base.comp_typing_u", "equation_Pulse.Typing.comp_post_matches_hint", "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", - "equation_Pulse.Typing.universe_of", "fuel_guarded_inversion_FStar.Pervasives.dtuple3", - "fuel_guarded_inversion_FStar.Pervasives.dtuple4", "fuel_guarded_inversion_Prims.dtuple2", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", + "fuel_guarded_inversion_Pulse.Typing.comp_typing", "function_token_typing_Prims.__cache_version_number__", "int_inversion", - "interpretation_Tm_abs_9627aa63c90056f8b614da4dfb4d20bf", - "interpretation_Tm_abs_ba86379e308bc452ec2aaf0d9384ea16", - "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", + "interpretation_Tm_abs_65bc593251765a404ad0a92141178dc4", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", "lemma_Pulse.Typing.Env.env_extends_trans", "lemma_Pulse.Typing.Env.push_env_as_map", - "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", + "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Some_v", "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", @@ -631,7 +623,6 @@ "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_u", - "refinement_interpretation_Tm_refine_1c5e7105979a7231f04ad65b46c30b69", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_2e7859babf6dc4b57292f015e044869d", "refinement_interpretation_Tm_refine_36441f5163bf4613efd69bece0701f67", @@ -639,19 +630,18 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", "refinement_interpretation_Tm_refine_c7355034ace971446067b77921ef4ff0", + "refinement_interpretation_Tm_refine_e077dd511289100be3832fc884204872", "typing_FStar.Pervasives.Native.__proj__Some__item__v", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", "typing_Pulse.Checker.Base.comp_st_with_post", - "typing_Pulse.Syntax.Base.uu___is_C_STGhost", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion", + "typing_Pulse.Typing.Metatheory.Base.st_typing_correctness", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "82624f020ad3014ae8615deccd66985b" + "a60acd755bbf6751357de00516d60569" ], [ "Pulse.Checker.Base.k_elab_equiv_prefix", @@ -659,9 +649,8 @@ 0, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", "bool_typing", + "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Syntax.Base.Mkst_comp", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", @@ -674,7 +663,6 @@ "equation_Pulse.Syntax.Base.st_comp_of_comp", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Typing.Combinators.frame_of", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_extends", @@ -683,46 +671,38 @@ "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", - "equation_Pulse.Typing.universe_of", - "fuel_guarded_inversion_FStar.Pervasives.dtuple4", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", "function_token_typing_Prims.__cache_version_number__", - "int_inversion", - "interpretation_Tm_abs_9627aa63c90056f8b614da4dfb4d20bf", - "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", - "kinding_Pulse.Syntax.Base.term@tok", + "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", "lemma_Pulse.Typing.Env.env_extends_trans", - "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", + "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Some_v", - "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Mkdtuple3__1", - "refinement_interpretation_Tm_refine_1c5e7105979a7231f04ad65b46c30b69", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_2e7859babf6dc4b57292f015e044869d", "refinement_interpretation_Tm_refine_4d5241eb6fe198666a8101195bbd4a2a", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "refinement_interpretation_Tm_refine_e077dd511289100be3832fc884204872", "refinement_interpretation_Tm_refine_e6b2fe059d644eadbc1b2088639b2786", "typing_FStar.Pervasives.Native.__proj__Some__item__v", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Syntax.Base.uu___is_C_STGhost", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion", + "typing_Pulse.Typing.Metatheory.Base.comp_typing_inversion", + "typing_Pulse.Typing.Metatheory.Base.st_typing_correctness", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "84d5f29c36c09d074fb7808b063b0b20" + "4a39bd4e359d91a1de1792a2ca5f4e39" ], [ "Pulse.Checker.Base.continuation_elaborator_with_bind", @@ -733,24 +713,28 @@ "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.lookup", + "fuel_guarded_inversion_FStar.Pervasives.Native.tuple2", + "kinding_Pulse.Syntax.Base.ppname@tok", + "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_Pulse.Typing.Env.env_extends_push", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_385f59c31213d29cc308b93df5d99dc9", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Syntax.Base.ppname_default", - "typing_Pulse.Typing.Env.as_map" + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", + "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Reflection.V2.Data.var", + "typing_Pulse.Syntax.Base.comp_res", "typing_Pulse.Typing.Env.as_map" ], 0, - "bd6f6fd0de5961b50479d90fad2ceb2f" + "6aa71b89ef41bf8faf8dd2026d5ef8a0" ], [ "Pulse.Checker.Base.continuation_elaborator_with_bind", @@ -759,25 +743,19 @@ 2, [ "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", "@fuel_correspondence_Pulse.Syntax.Naming.subst_term.fuel_instrumented", "@fuel_irrelevance_Pulse.Syntax.Naming.subst_term.fuel_instrumented", - "@query", - "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.Mkterm", "constructor_distinct_Pulse.Syntax.Base.Tm_Emp", - "constructor_distinct_Pulse.Syntax.Base.Tm_FStar", "constructor_distinct_Pulse.Syntax.Base.Tm_Inames", "constructor_distinct_Pulse.Syntax.Base.Tm_Star", - "constructor_distinct_Tm_unit", - "data_elim_FStar.Pervasives.Mkdtuple4", + "data_elim_FStar.Pervasives.Native.Mktuple2", "data_elim_FStar.Pervasives.Native.Some", - "data_elim_Prims.Mkdtuple2", "data_elim_Pulse.Syntax.Base.Mkst_comp", - "data_elim_Pulse.Syntax.Base.Mkterm", - "data_elim_Pulse.Syntax.Base.Tm_Pure", + "data_elim_Prims.Mkdtuple2", "data_elim_Pulse.Syntax.Base.Mkppname", + "data_elim_Pulse.Syntax.Base.Mkst_comp", "data_typing_intro_Prims.Cons@tok", "data_typing_intro_Prims.Nil@tok", "data_typing_intro_Pulse.Syntax.Naming.DT@tok", @@ -789,9 +767,9 @@ "disc_equation_Pulse.Syntax.Base.C_Tot", "equality_tok_Pulse.Syntax.Base.Tm_Inames@tok", "equation_FStar.Pervasives.Native.fst", - "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", + "equation_FStar.Reflection.Typing.pp_name_t", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", @@ -803,7 +781,6 @@ "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.st_comp_of_comp", "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.tm_fstar", "equation_Pulse.Syntax.Base.tm_star", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.v_as_nv", @@ -818,7 +795,6 @@ "equation_Pulse.Syntax.Pure.tm_type", "equation_Pulse.Typing.Combinators.frame_of", "equation_Pulse.Typing.Combinators.st_comp_with_pre", - "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", @@ -827,26 +803,22 @@ "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", - "equation_Pulse.Typing.tot_typing", "equation_Pulse.Typing.typing", - "equation_Pulse.Typing.universe_of", - "equation_with_fuel_Pulse.Syntax.Naming.freevars.fuel_instrumented", + "equation_Pulse.Typing.tot_typing", "equation_with_fuel_Pulse.Syntax.Naming.subst_term.fuel_instrumented", "fuel_guarded_inversion_FStar.Pervasives.Native.option", - "fuel_guarded_inversion_FStar.Pervasives.dtuple4", + "fuel_guarded_inversion_FStar.Pervasives.Native.tuple2", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Prims.dtuple2", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", - "fuel_guarded_inversion_Pulse.Syntax.Base.term_", "fuel_guarded_inversion_Pulse.Typing.my_erased", "fuel_guarded_inversion_Pulse.Typing.post_hint_t", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "int_typing", - "interpretation_Tm_abs_9627aa63c90056f8b614da4dfb4d20bf", - "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", + "function_token_typing_Prims.string", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_typing", "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Syntax.Naming.subst_elt@tok", @@ -854,17 +826,17 @@ "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Pervasives.invertOption", - "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_FStar.Set.mem_union", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", + "lemma_Pulse.Typing.Env.env_extends_trans", "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.post_hint_for_env_extends", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "primitive_Prims.op_Negation", + "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", @@ -874,13 +846,12 @@ "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Mkdtuple3__1", - "projection_inverse_FStar.Pervasives.Mkdtuple4__3", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_FStar.Pervasives.Native.Some_a", - "projection_inverse_FStar.Pervasives.Native.Some_v", "projection_inverse_Prims.Mkdtuple2__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_post", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", @@ -894,23 +865,24 @@ "refinement_interpretation_Tm_refine_2e7859babf6dc4b57292f015e044869d", "refinement_interpretation_Tm_refine_385f59c31213d29cc308b93df5d99dc9", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_4d5241eb6fe198666a8101195bbd4a2a", + "refinement_interpretation_Tm_refine_507cff99cfaf1de8769ad73117f794c9", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_91f4f5b5584335b3faf6de950032f9c5", - "refinement_interpretation_Tm_refine_9491aaa29a977da7de92f5e9b2712f87", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", "refinement_interpretation_Tm_refine_c985d9b653dbe863d90ae1101a9c9392", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "token_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", - "typing_FStar.Map.contains", + "string_typing", "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", "typing_FStar.Pervasives.Native.__proj__Some__item__v", + "typing_FStar.Pervasives.Native.fst", "typing_FStar.Pervasives.Native.snd", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__post", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.comp_post", @@ -921,18 +893,15 @@ "typing_Pulse.Syntax.Base.tm_star", "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Syntax.Naming.freevars", + "typing_Pulse.Syntax.Naming.open_term", "typing_Pulse.Syntax.Naming.open_term_nv", "typing_Pulse.Syntax.Pure.term_of_nvar", "typing_Pulse.Typing.Combinators.apply_frame", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.lookup", - "typing_Pulse.Typing.Metatheory.comp_typing_inversion", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion", - "typing_Pulse.Typing.Metatheory.st_typing_correctness", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "5786b728bca575e98eebde596d0e39f0" + "680318e29139e19bb3d75e4079a92233" ], [ "Pulse.Checker.Base.continuation_elaborator_with_tot_bind", @@ -943,23 +912,27 @@ "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", + "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.lookup", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", + "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_Pulse.Typing.Env.env_extends_push", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", + "typing_FStar.Reflection.V2.Data.var", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Typing.Env.as_map" ], 0, - "69f92a526ec7b2bc87c7672443c227f8" + "726b218140b6ee9b91c33bdc15b5e562" ], [ "Pulse.Checker.Base.continuation_elaborator_with_tot_bind", @@ -967,35 +940,36 @@ 1, 1, [ - "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_Pulse.Syntax.Naming.subst_term.fuel_instrumented", - "@query", "bool_inversion", + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", - "constructor_distinct_FStar.Tactics.Result.Failed", - "constructor_distinct_FStar.Tactics.Result.Success", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "data_elim_FStar.Pervasives.Mkdtuple3", - "data_typing_intro_Prims.Cons@tok", - "data_typing_intro_Prims.Nil@tok", - "data_typing_intro_Pulse.Syntax.Naming.DT@tok", - "data_typing_intro_Pulse.Syntax.Naming.ND@tok", + "data_elim_FStar.Pervasives.Native.Mktuple2", + "data_elim_Pulse.Syntax.Base.Mkppname", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.subset", - "equation_Prims.eqtype", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_post", - "equation_Pulse.Syntax.Base.comp_pre", - "equation_Pulse.Syntax.Base.comp_res", - "equation_Pulse.Syntax.Base.comp_u", - "equation_Pulse.Syntax.Base.index", + "equation_FStar.Pervasives.Native.fst", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", + "equation_FStar.Reflection.Typing.pp_name_t", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", + "equation_FStar.Set.subset", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_pre", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.v_as_nv", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Naming.close_comp", "equation_Pulse.Syntax.Naming.close_comp_", "equation_Pulse.Syntax.Naming.close_term_", @@ -1004,74 +978,77 @@ "equation_Pulse.Syntax.Naming.open_comp_with", "equation_Pulse.Syntax.Naming.open_st_term", "equation_Pulse.Syntax.Naming.open_term_", - "equation_Pulse.Syntax.Naming.subst", "equation_Pulse.Syntax.Naming.subst_comp", "equation_Pulse.Syntax.Naming.subst_st_comp", - "equation_Pulse.Typing.Combinators.st_typing_in_ctxt", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.FV.vars_of_env", "equation_Pulse.Typing.comp_post_matches_hint", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", - "equation_with_fuel_Pulse.Syntax.Naming.subst_term.fuel_instrumented", - "fuel_guarded_inversion_FStar.Pervasives.dtuple3", + "fuel_guarded_inversion_FStar.Pervasives.Native.tuple2", + "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "int_typing", - "interpretation_Tm_abs_ba86379e308bc452ec2aaf0d9384ea16", + "function_token_typing_Prims.string", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", + "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", - "kinding_Pulse.Syntax.Naming.subst_elt@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.post_hint_for_env_extends", - "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", + "lemma_Pulse.Typing.Env.env_extends_trans", + "primitive_Prims.op_BarBar", + "proj_equation_FStar.Pervasives.Native.Mktuple2__1", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", - "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Mkdtuple3__2", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_FStar.Pervasives.Native.Some_a", "projection_inverse_FStar.Pervasives.Native.Some_v", - "projection_inverse_FStar.Tactics.Result.Failed_a", - "projection_inverse_FStar.Tactics.Result.Failed_exn", - "projection_inverse_FStar.Tactics.Result.Failed_ps", - "projection_inverse_FStar.Tactics.Result.Success_a", - "projection_inverse_FStar.Tactics.Result.Success_ps", - "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_1c5e7105979a7231f04ad65b46c30b69", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_4d5241eb6fe198666a8101195bbd4a2a", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "typing_FStar.Map.contains", + "refinement_interpretation_Tm_refine_e077dd511289100be3832fc884204872", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "string_typing", "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", "typing_FStar.Pervasives.Native.__proj__Some__item__v", - "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Pervasives.Native.snd", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.ppname_default", - "typing_Pulse.Syntax.Base.stateful_comp", - "typing_Pulse.Syntax.Naming.subst_term", + "typing_Pulse.Syntax.Base.v_as_nv", + "typing_Pulse.Syntax.Naming.close_comp", + "typing_Pulse.Syntax.Naming.open_comp_with", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "2e78593d45e56be7ecac842decd04575" + "94f5f77273650d1652df58bedbe07246" ], [ "Pulse.Checker.Base.check_equiv_emp", @@ -1101,7 +1078,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t" ], 0, - "b795bae0f264efa4143d35e0369f52a6" + "9f7c0e128a146e080228cefcc10a0952" ], [ "Pulse.Checker.Base.checker_res_matches_post_hint", @@ -1118,15 +1095,6 @@ 0, "7984897218078f268849ee492a78bcbf" ], - [ - "Pulse.Checker.Base.checker_result_t", - 1, - 1, - 1, - [ "@query" ], - 0, - "5834b34d4b86f26323d5e5535d399a01" - ], [ "Pulse.Checker.Base.intro_comp_typing", 1, @@ -1156,7 +1124,7 @@ "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "732a129364c8ecaedafc8e1fd0917f87" + "1bac41546c65dffc2796fa5dc43ec89b" ], [ "Pulse.Checker.Base.intro_comp_typing", @@ -1196,6 +1164,10 @@ 1, [ "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_FStar.Tactics.Result.Success", + "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", @@ -1207,11 +1179,15 @@ "equation_Pulse.Syntax.Base.comp_u", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.tm_inames", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.fresh_wrt", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Tactics.Result.Success_a", + "projection_inverse_FStar.Tactics.Result.Success_ps", + "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", @@ -1219,11 +1195,11 @@ "refinement_interpretation_Tm_refine_b1a323d97082b88bad74885f3f1e4f57", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "refinement_interpretation_Tm_refine_fbeb4eb12902ab763889d17cad7e9920", - "typing_Pulse.Syntax.Base.eq_tm", + "string_typing", "typing_Pulse.Syntax.Base.eq_tm", "typing_Pulse.Syntax.Base.tm_inames" ], 0, - "561ffecc22bf48cbd2b7378a1619df06" + "e2094c2a468197b903561baa80639558" ], [ "Pulse.Checker.Base.return_in_ctxt", @@ -1256,6 +1232,7 @@ "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.v_as_nv", @@ -1273,6 +1250,7 @@ "equation_Pulse.Typing.comp_return", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.ctag", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.int", @@ -1280,10 +1258,7 @@ "kinding_Pulse.Syntax.Base.ctag@tok", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Pervasives.invertOption", - "lemma_Pulse.Typing.Env.push_env_as_map", - "primitive_Prims.op_BarBar", + "lemma_FStar.Pervasives.invertOption", "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", @@ -1299,7 +1274,6 @@ "projection_inverse_FStar.Pervasives.Native.Some_v", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_post", @@ -1309,15 +1283,17 @@ "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", - "typing_Pulse.Typing.Env.dom", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Pure.null_var", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__ctag_hint", - "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" + "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__post", + "typing_Pulse.Typing.comp_return" ], 0, - "b92706ebc21986002c0d524aa5174189" + "005e2c984bb87a81e4c0e5c88c2f384e" ], [ "Pulse.Checker.Base.apply_checker_result_k", @@ -1332,7 +1308,7 @@ "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384" ], 0, - "012ff42cfebcc901f37c981cdf8eba99" + "4f890e4da8e7ff162d6d2086d5ee1a4f" ], [ "Pulse.Checker.Base.apply_checker_result_k", @@ -1360,36 +1336,44 @@ "data_elim_FStar.Pervasives.Mkdtuple5", "disc_equation_FStar.Pervasives.Native.Some", "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", "equation_Pulse.Checker.Base.checker_result_t", + "equation_Pulse.Syntax.Base.universe", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.post_hint_for_env", "equation_Pulse.Typing.post_hint_for_env_p", + "fuel_guarded_inversion_FStar.Pervasives.dtuple3", "fuel_guarded_inversion_FStar.Pervasives.dtuple5", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Prims.dtuple2", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", - "interpretation_Tm_abs_60a5aa96ff1da220b9fe042919aec14c", - "interpretation_Tm_abs_a7c07c7cfa7388d556bc16f9e2978a91", - "interpretation_Tm_abs_edbc06d5ff9cf8ed2ddc9fe1910c602d", + "interpretation_Tm_abs_3c40274298c18b3c60fac0d11fae8431", + "interpretation_Tm_abs_5adeb3a78b1b342e9d9bdc8b1e2ca123", + "interpretation_Tm_abs_e21586ea0dcb2b831fcc0617ea281b2d", + "interpretation_Tm_abs_f9ba06e91f9754038708331844af2d35", "lemma_Pulse.Typing.Env.env_extends_trans", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Prims.Mkdtuple2__1", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Mkdtuple3__2", "projection_inverse_FStar.Pervasives.Mkdtuple5__1", "projection_inverse_FStar.Pervasives.Mkdtuple5__2", "projection_inverse_FStar.Pervasives.Mkdtuple5__3", "projection_inverse_FStar.Pervasives.Mkdtuple5__4", "projection_inverse_FStar.Pervasives.Native.Some_a", "projection_inverse_FStar.Pervasives.Native.Some_v", - "refinement_interpretation_Tm_refine_0e7cec6ed8f6e8567fd60faa69f1ee6b", + "projection_inverse_Prims.Mkdtuple2__1", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_6d8ee78207eb8c69f5e44f08014b2ba6", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", + "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", + "refinement_interpretation_Tm_refine_b0ea3495ff282f69439c9d1354d6b870", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "b3825439fa1fac456f68eceaee0e138a" + "a915427c40bd90277ba3044cd71d2d00" ], [ "Pulse.Checker.Base.checker_result_for_st_typing", @@ -1397,19 +1381,17 @@ 0, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", "bool_typing", + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", + "bool_inversion", "bool_typing", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", - "constructor_distinct_FStar.Tactics.Result.Failed", - "constructor_distinct_FStar.Tactics.Result.Success", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", "constructor_distinct_Pulse.Syntax.Base.C_Tot", "data_elim_FStar.Pervasives.Mkdtuple3", - "data_elim_Pulse.Typing.T_Bind", - "data_elim_Pulse.Typing.T_ElimExists", - "data_elim_Pulse.Typing.T_Par", "data_elim_Pulse.Typing.T_Return", - "data_elim_Pulse.Typing.T_TotBind", + "data_elim_Pulse.Syntax.Base.Mkst_comp", "data_elim_Pulse.Typing.T_WithLocal", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_FStar.Pervasives.Native.Some", @@ -1419,18 +1401,28 @@ "disc_equation_Pulse.Syntax.Base.C_Tot", "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", + "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.comp_u", + "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.st_comp_of_comp", "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.tm_emp", - "equation_Pulse.Syntax.Base.tm_star", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.universe", "equation_Pulse.Syntax.Base.v_as_nv", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Syntax.Naming.open_term", "equation_Pulse.Typing.Combinators.st_typing_in_ctxt", + "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", @@ -1443,31 +1435,41 @@ "equation_Pulse.Typing.comp_post_matches_hint", "equation_Pulse.Typing.comp_rewrite", "equation_Pulse.Typing.comp_while", + "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Pervasives.dtuple3", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "fuel_guarded_inversion_Pulse.Typing.st_typing", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", - "interpretation_Tm_abs_ba86379e308bc452ec2aaf0d9384ea16", + "function_token_typing_Prims.string", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_typing", + "interpretation_Tm_abs_65bc593251765a404ad0a92141178dc4", + "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomUpd1", "lemma_FStar.Map.lemma_SelUpd1", "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", "lemma_Pulse.Typing.Env.push_binding_as_map", "primitive_Prims.op_BarBar", "primitive_Prims.op_Equality", - "primitive_Prims.op_Negation", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", - "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", + "proj_equation_Pulse.Syntax.Base.Mkppname_range", + "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", + "proj_equation_Pulse.Syntax.Base.Mkst_comp_u", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Mkdtuple3__1", @@ -1475,34 +1477,33 @@ "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", - "projection_inverse_FStar.Tactics.Result.Failed_a", - "projection_inverse_FStar.Tactics.Result.Failed_exn", - "projection_inverse_FStar.Tactics.Result.Failed_ps", - "projection_inverse_FStar.Tactics.Result.Success_a", - "projection_inverse_FStar.Tactics.Result.Success_ps", - "projection_inverse_FStar.Tactics.Result.Success_v", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", - "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", + "projection_inverse_Prims.Mkdtuple2__1", + "projection_inverse_Pulse.Syntax.Base.C_Tot__0", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_1c5e7105979a7231f04ad65b46c30b69", - "refinement_interpretation_Tm_refine_1e3b46ef574b7c7b56e6f48d45a4bd20", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_2e7859babf6dc4b57292f015e044869d", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", "refinement_interpretation_Tm_refine_d79470205dca7f56c9b5a5da9d23b961", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "refinement_interpretation_Tm_refine_f327b3b66854e57c59289f8c259581e7", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.comp_res", + "refinement_interpretation_Tm_refine_e077dd511289100be3832fc884204872", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "string_typing", "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", + "typing_Pulse.Syntax.Base.comp_res", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Base.stateful_comp", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.lookup", - "typing_Pulse.Typing.Env.push_binding", "typing_Pulse.Typing.tm_unit" + "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Typing.Env.as_map", + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.lookup" ], 0, - "31c5b86fa1e87f82541bf69bb532eca3" + "7e5740e6bd2c194133babfa0fa9f247b" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Base.fsti b/lib/steel/pulse/Pulse.Checker.Base.fsti index 78426adba..151c49e8d 100644 --- a/lib/steel/pulse/Pulse.Checker.Base.fsti +++ b/lib/steel/pulse/Pulse.Checker.Base.fsti @@ -52,20 +52,22 @@ val continuation_elaborator_with_bind (#g:env) (ctxt:term) (#e1:st_term) (e1_typing:st_typing g e1 c1) (ctxt_pre1_typing:tot_typing g (tm_star ctxt (comp_pre c1)) tm_vprop) - (x:var { None? (lookup g x) }) + (x:nvar { None? (lookup g (snd x)) }) : T.Tac (continuation_elaborator - g (tm_star ctxt (comp_pre c1)) - (push_binding g x ppname_default (comp_res c1)) (tm_star (open_term (comp_post c1) x) ctxt)) + g + (tm_star ctxt (comp_pre c1)) + (push_binding g (snd x) (fst x) (comp_res c1)) + (tm_star (open_term (comp_post c1) (snd x)) ctxt)) val continuation_elaborator_with_tot_bind (#g:env) (#ctxt:term) (ctxt_typing:tot_typing g ctxt tm_vprop) (#e1:term) (#t1:term) (e1_typing:tot_typing g e1 t1) - (x:var { None? (lookup g x) }) + (x:nvar { None? (lookup g (snd x)) }) : T.Tac (continuation_elaborator g ctxt - (push_binding g x ppname_default t1) ctxt) + (push_binding g (snd x) ppname_default t1) ctxt) val check_equiv_emp (g:env) (vp:term) : option (vprop_equiv g vp tm_emp) @@ -81,24 +83,36 @@ let checker_res_matches_post_hint t == post_hint.ret_ty /\ ctxt' == open_term post_hint.post x +let checker_result_inv (g:env) (post_hint:post_hint_opt g) + (x:var) + (g1:env) + (t:(u:universe & t:term & universe_of g1 t u)) + (ctxt':(ctxt':vprop & tot_typing g1 ctxt' tm_vprop)) = + + let (| _, t, _ |) = t in + let (| ctxt', _ |) = ctxt' in + checker_res_matches_post_hint g post_hint x t ctxt' /\ + lookup g1 x == Some t + // // x is the variable in which the result of the checked computation is bound // t is the type of the checked computation // -// TODO: return ctxt' typing so that the continuation can use it -// type checker_result_t (g:env) (ctxt:vprop) (post_hint:post_hint_opt g) = x:var & - t:term & - ctxt':vprop { checker_res_matches_post_hint g post_hint x t ctxt' } & - g1:env { g1 `env_extends` g /\ lookup g1 x == Some t } & - continuation_elaborator g ctxt g1 ctxt' + g1:env { g1 `env_extends` g } & + t:(u:universe & t:typ & universe_of g1 t u) & + ctxt':(ctxt':vprop & tot_typing g1 ctxt' tm_vprop) & + k:continuation_elaborator g ctxt g1 (dfst ctxt') { + checker_result_inv g post_hint x g1 t ctxt' + } type check_t = g:env -> ctxt:vprop -> ctxt_typing:tot_typing g ctxt tm_vprop -> post_hint:post_hint_opt g -> + res_ppname:ppname -> t:st_term -> T.Tac (checker_result_t g ctxt post_hint) @@ -112,8 +126,10 @@ val intro_comp_typing (g:env) val apply_checker_result_k (#g:env) (#ctxt:vprop) (#post_hint:post_hint_for_env g) (r:checker_result_t g ctxt (Some post_hint)) + (res_ppname:ppname) : T.Tac (st_typing_in_ctxt g ctxt (Some post_hint)) val checker_result_for_st_typing (#g:env) (#ctxt:vprop) (#post_hint:post_hint_opt g) (d:st_typing_in_ctxt g ctxt post_hint) + (ppname:ppname) : T.Tac (checker_result_t g ctxt post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Base.fsti.hints b/lib/steel/pulse/Pulse.Checker.Base.fsti.hints index 28670521f..2f4853511 100644 --- a/lib/steel/pulse/Pulse.Checker.Base.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Base.fsti.hints @@ -1,5 +1,5 @@ [ - "\r\u0001\u0011*\u0006\u001e&̓} k", + "_ڇY}l*6h\"\u0015", [ [ "Pulse.Checker.Base.continuation_elaborator", @@ -22,7 +22,7 @@ "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "ee66df5607866de039bfff7bbfd46191" + "fe99e051b8a332d1e9689d64b80f7114" ], [ "Pulse.Checker.Base.k_elab_unit", @@ -56,24 +56,28 @@ "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.lookup", + "fuel_guarded_inversion_FStar.Pervasives.Native.tuple2", + "kinding_Pulse.Syntax.Base.ppname@tok", + "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_Pulse.Typing.Env.env_extends_push", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_385f59c31213d29cc308b93df5d99dc9", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Syntax.Base.ppname_default", - "typing_Pulse.Typing.Env.as_map" + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", + "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Reflection.V2.Data.var", + "typing_Pulse.Syntax.Base.comp_res", "typing_Pulse.Typing.Env.as_map" ], 0, - "36412cf9ab1255168a8fb874ddd95b6b" + "4b236f77c50f6ce21d05b9a5365a5186" ], [ "Pulse.Checker.Base.continuation_elaborator_with_tot_bind", @@ -84,23 +88,27 @@ "@MaxIFuel_assumption", "@query", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", + "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.lookup", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", + "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_Pulse.Typing.Env.env_extends_push", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", + "refinement_interpretation_Tm_refine_42683f02c4ca4e60fa6e6c8a4bb2b246", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Map.contains", + "typing_FStar.Pervasives.Native.__proj__Mktuple2__item___2", + "typing_FStar.Reflection.V2.Data.var", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Typing.Env.as_map" ], 0, - "49f290b9f1817a0de06aecc604dbb42a" + "db039ad4d873e638eb7fc05eccd3fe2c" ], [ "Pulse.Checker.Base.checker_res_matches_post_hint", @@ -117,15 +125,6 @@ 0, "fb2a53c36a7166939ec9762275ea5c33" ], - [ - "Pulse.Checker.Base.checker_result_t", - 1, - 2, - 1, - [ "@query" ], - 0, - "10a99e5e35418b5be9d298a1d48fa107" - ], [ "Pulse.Checker.Base.intro_comp_typing", 1, @@ -155,7 +154,7 @@ "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "cf59dbc51f73ce1a8040121a820e1995" + "bc5373096a67ec6668bbc60d179d9fc9" ], [ "Pulse.Checker.Base.apply_checker_result_k", diff --git a/lib/steel/pulse/Pulse.Checker.Bind.fst b/lib/steel/pulse/Pulse.Checker.Bind.fst index a90f30b90..e76d1ba47 100644 --- a/lib/steel/pulse/Pulse.Checker.Bind.fst +++ b/lib/steel/pulse/Pulse.Checker.Bind.fst @@ -20,39 +20,46 @@ let check_bind (ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term {Tm_Bind? t.term}) (check:check_t) : T.Tac (checker_result_t g ctxt post_hint) = + let g = Pulse.Typing.Env.push_context g "check_bind" t.range in + debug_prover g (fun _ -> Printf.sprintf "checking bind:\n%s\n" (P.st_term_to_string t)); if None? post_hint - then fail g (Some t.range) "check_bind: post_hint is None, bailing (t:\n%s\n)"; + then fail g (Some t.range) "check_bind: post hint is not set, please add an annotation"; let Tm_Bind { binder; head=e1; body=e2} = t.term in - let (| x, ty, ctxt', g1, k1 |) = - check g ctxt ctxt_typing None e1 in - - let r = - check g1 ctxt' (magic ()) post_hint (open_st_term_nv e2 (binder.binder_ppname, x)) in - let d : st_typing_in_ctxt g1 ctxt' post_hint = apply_checker_result_k #_ #_ #(Some?.v post_hint) r in + let (| x, g1, _, (| ctxt', ctxt'_typing |), k1 |) = + check g ctxt ctxt_typing None binder.binder_ppname e1 in + let d : st_typing_in_ctxt g1 ctxt' post_hint = + let ppname = mk_ppname_no_range "_bind_c" in + let r = + check g1 ctxt' ctxt'_typing post_hint ppname (open_st_term_nv e2 (binder.binder_ppname, x)) in + apply_checker_result_k #_ #_ #(Some?.v post_hint) r ppname in let d : st_typing_in_ctxt g ctxt post_hint = k1 post_hint d in - checker_result_for_st_typing d + checker_result_for_st_typing d res_ppname let check_tot_bind (g:env) (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_TotBind? t.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_bind" t.range in + if None? post_hint - then fail g (Some t.range) "check_tot_bind: post_hint is None, bailing (t:\n%s\n)"; + then fail g (Some t.range) "check_tot_bind: post hint is not set, please add an annotation"; let Tm_TotBind { head=e1; body=e2 } = t.term in let (| e1, u1, t1, _t1_typing, e1_typing |) = check_term_and_type g e1 in @@ -67,13 +74,15 @@ let check_tot_bind let x = fresh g in - let k = continuation_elaborator_with_tot_bind pre_typing (E e1_typing) x in + let k = continuation_elaborator_with_tot_bind pre_typing (E e1_typing) (ppname_default, x) in let px = v_as_nv x in let g' = push_binding g x (fst px) t1 in let pre_typing' : tot_typing g' pre tm_vprop = - Metatheory.tot_typing_weakening1 x t1 pre_typing in - let r = check g' pre pre_typing' post_hint (open_st_term_nv e2 px) in - let d = apply_checker_result_k #_ #_ #(Some?.v post_hint) r in + Metatheory.tot_typing_weakening_single pre_typing x t1 in + let d = + let ppname = mk_ppname_no_range "_tbind_c" in + let r = check g' pre pre_typing' post_hint ppname (open_st_term_nv e2 px) in + apply_checker_result_k #_ #_ #(Some?.v post_hint) r ppname in let d = k post_hint d in - checker_result_for_st_typing d + checker_result_for_st_typing d res_ppname diff --git a/lib/steel/pulse/Pulse.Checker.Bind.fst.hints b/lib/steel/pulse/Pulse.Checker.Bind.fst.hints index b8eb37e79..0226f3e5d 100644 --- a/lib/steel/pulse/Pulse.Checker.Bind.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Bind.fst.hints @@ -1,5 +1,5 @@ [ - "`\n:ZVI\u0014\u0017-\u0012\u0019", + "\u000b4\u0018K^YC\u007fwD]", [ [ "Pulse.Checker.Bind.coerce_eq", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_0dee8cb03258a67c2f7ec66427696212" ], 0, - "4a65852a73b443b0ce4095efb1247549" + "74e8ddbb581ec7cbe46659b7ec14cd9e" ], [ "Pulse.Checker.Bind.check_bind", @@ -24,21 +24,34 @@ "Pulse.Typing_pretyping_85b09ae4ef91823fbf549acd09fde244", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", + "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", "constructor_distinct_FStar.Tactics.Result.Success", "data_elim_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Syntax.Base.Mkst_term", + "data_elim_Pulse.Syntax.Base.Mkterm", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_FStar.Pervasives.Native.Some", + "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", + "equation_FStar.Range.range", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.tm_vprop", + "equation_Pulse.Syntax.Base.with_range", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "kinding_Pulse.Typing.post_hint_t@tok", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", + "function_token_typing_Prims.__cache_version_number__", + "int_inversion", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Pervasives.invertOption", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_trans", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.None_a", @@ -48,13 +61,19 @@ "projection_inverse_FStar.Tactics.Result.Success_a", "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", - "refinement_interpretation_Tm_refine_0e7cec6ed8f6e8567fd60faa69f1ee6b", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", + "refinement_interpretation_Tm_refine_cae545c65785ca4f8e3707a9a089ca19", "refinement_interpretation_Tm_refine_da369f128845038617bacd99a355825a", - "string_typing", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", "typing_Pulse.Syntax.Base.tm_vprop", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context", + "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "18e5d89290b42913ea2fe9131ef2d3ee" + "7a4c9aed703e264c15583b4acb45003c" ], [ "Pulse.Checker.Bind.check_tot_bind", @@ -70,42 +89,44 @@ "constructor_distinct_FStar.Tactics.Result.Failed", "constructor_distinct_FStar.Tactics.Result.Success", "data_elim_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Syntax.Base.Mkst_term", "data_typing_intro_Pulse.Syntax.Base.Mkbinder@tok", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_FStar.Pervasives.Native.Some", "equation_FStar.Pervasives.Native.fst", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.index", - "equation_Pulse.Syntax.Base.ppname_default", - "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.v_as_nv", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Pure.tm_refine", - "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.int", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_typing", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", - "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.mem_empty", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", "lemma_Pulse.Typing.post_hint_for_env_extends", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_FStar.Tactics.Result.Failed_a", "projection_inverse_FStar.Tactics.Result.Failed_exn", @@ -113,22 +134,25 @@ "projection_inverse_FStar.Tactics.Result.Success_a", "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_594c2e7ce8a09f39c084a6d39b86d7e6", + "refinement_interpretation_Tm_refine_63dbd67f17741239afac25c89ad1839d", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Pure.null_bvar", "typing_Pulse.Syntax.Pure.tm_refine", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g", - "typing_Pulse.Typing.mk_eq2" + "typing_Pulse.Typing.Env.fresh", + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.mk_eq2" ], 0, - "78c5414e0d5568bac5542197c45f87dd" + "c9928bb5771003a81e5ac7ea4fa9b82a" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Bind.fsti b/lib/steel/pulse/Pulse.Checker.Bind.fsti index 3d56ae00e..e0247b34b 100644 --- a/lib/steel/pulse/Pulse.Checker.Bind.fsti +++ b/lib/steel/pulse/Pulse.Checker.Bind.fsti @@ -11,6 +11,7 @@ val check_bind (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_Bind? t.term}) (check:check_t) : T.Tac (checker_result_t g pre post_hint) @@ -20,6 +21,7 @@ val check_tot_bind (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_TotBind? t.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Bind.fsti.hints b/lib/steel/pulse/Pulse.Checker.Bind.fsti.hints index c0eb75562..843a053de 100644 --- a/lib/steel/pulse/Pulse.Checker.Bind.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Bind.fsti.hints @@ -1 +1 @@ -[ "i\u0003RFImk2?", [] ] \ No newline at end of file +[ "^nԢ`\u001e!#h", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Comp.fst b/lib/steel/pulse/Pulse.Checker.Comp.fst index fd58de814..43e022f81 100644 --- a/lib/steel/pulse/Pulse.Checker.Comp.fst +++ b/lib/steel/pulse/Pulse.Checker.Comp.fst @@ -5,19 +5,27 @@ open Pulse.Typing open Pulse.Checker.Pure module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer let check (g:env) (c:comp_st) (pre_typing:tot_typing g (comp_pre c) tm_vprop) : T.Tac (comp_typing g c (comp_u c)) - = let check_st_comp (st:st_comp { comp_u c == st.u /\ + = let g = Pulse.Typing.Env.push_context_no_range g "check_comp" in + + let check_st_comp (st:st_comp { comp_u c == st.u /\ comp_pre c == st.pre /\ comp_res c == st.res /\ comp_post c == st.post } ) : T.Tac (st_comp_typing g st) = let (| u, t_u |) = check_universe g st.res in if not (eq_univ u (comp_u c)) - then fail g None "Unexpected universe" + then fail g None + (Printf.sprintf "check_comp: computed universe of %s as %s, whereas annotated as %s" + (P.term_to_string st.res) + (P.univ_to_string u) + (P.univ_to_string (comp_u c))) + else ( let x = fresh g in let px = v_as_nv x in @@ -25,7 +33,8 @@ let check (g:env) let gx = push_binding g x (fst px) st.res in let (| ty, post_typing |) = core_check_term gx (open_term_nv (comp_post c) px) in if not (eq_tm ty tm_vprop) - then fail g None "Ill-typed postcondition" + then fail g None + (Printf.sprintf "check_comp: ill-typed postcondition %s" (P.term_to_string (comp_post c))) else ( assert (ty == tm_vprop); STC g st x t_u pre_typing (E post_typing) @@ -40,11 +49,15 @@ let check (g:env) let stc = check_st_comp st in let (| ty, i_typing |) = core_check_term g i in if not (eq_tm ty tm_inames) - then fail g None "Ill-typed inames" + then fail g None + (Printf.sprintf "check_comp: type of inames term %s is %s, expected %s" + (P.term_to_string i) (P.term_to_string ty) (P.term_to_string tm_inames)) else CT_STAtomic _ _ _ (E i_typing) stc | C_STGhost i st -> let stc = check_st_comp st in let (| ty, i_typing |) = core_check_term g i in if not (eq_tm ty tm_inames) - then fail g None "Ill-typed inames" + then fail g None + (Printf.sprintf "check_comp: type of inames term %s is %s, expected %s" + (P.term_to_string i) (P.term_to_string ty) (P.term_to_string tm_inames)) else CT_STGhost _ _ _ (E i_typing) stc diff --git a/lib/steel/pulse/Pulse.Checker.Comp.fst.hints b/lib/steel/pulse/Pulse.Checker.Comp.fst.hints index f2cd974cc..f4ef9eef8 100644 --- a/lib/steel/pulse/Pulse.Checker.Comp.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Comp.fst.hints @@ -1,5 +1,5 @@ [ - "\\?P\nFJ", + "᷋CC`$t:", [ [ "Pulse.Checker.Comp.check", @@ -19,7 +19,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "c5fbe969299672d45c19dcd755e9c6eb" + "24666984abe0e119f1746676b60418e1" ], [ "Pulse.Checker.Comp.check", @@ -47,8 +47,12 @@ 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_FStar.Tactics.Result.Failed", + "constructor_distinct_FStar.Tactics.Result.Success", "constructor_distinct_Pulse.Syntax.Base.C_ST", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", @@ -57,6 +61,7 @@ "disc_equation_Pulse.Syntax.Base.C_Tot", "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", @@ -73,8 +78,9 @@ "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", @@ -84,23 +90,34 @@ "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", + "projection_inverse_FStar.Tactics.Result.Failed_a", + "projection_inverse_FStar.Tactics.Result.Failed_exn", + "projection_inverse_FStar.Tactics.Result.Failed_ps", + "projection_inverse_FStar.Tactics.Result.Success_a", + "projection_inverse_FStar.Tactics.Result.Success_ps", + "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_76d7c7ff95222e5f6fb2057459f0bce4", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_b1a323d97082b88bad74885f3f1e4f57", + "refinement_interpretation_Tm_refine_c556d8c6ca97b6a4ca0a5af8ca937017", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Syntax.Base.eq_tm", + "string_typing", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__u", + "typing_Pulse.Syntax.Base.eq_tm", "typing_Pulse.Syntax.Base.eq_univ", "typing_Pulse.Syntax.Base.tm_inames", "typing_Pulse.Syntax.Base.tm_vprop", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context_no_range" ], 0, - "da166921062fafdc5de1819973728c0d" + "b21c779da87247a74b3c6b560772d124" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Comp.fsti.hints b/lib/steel/pulse/Pulse.Checker.Comp.fsti.hints index 7ddb6dddc..ca2242489 100644 --- a/lib/steel/pulse/Pulse.Checker.Comp.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Comp.fsti.hints @@ -19,7 +19,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "06fc1c0f18afa7e2cab16cbd29dd33f5" + "622c8269dfeca6ced45126b249662c3a" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Exists.fst b/lib/steel/pulse/Pulse.Checker.Exists.fst index 27c6d68eb..ffb0c2b05 100644 --- a/lib/steel/pulse/Pulse.Checker.Exists.fst +++ b/lib/steel/pulse/Pulse.Checker.Exists.fst @@ -29,9 +29,12 @@ let check_elim_exists (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_ElimExists? t.term}) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_elim_exists" t.range in + let Tm_ElimExists { p = t } = t.term in let (| t, t_typing |) : (t:term & tot_typing g t tm_vprop ) = match t.t with @@ -44,7 +47,7 @@ let check_elim_exists assume (one `List.Tot.memP` ts); (| one, vprop_as_list_typing pre_typing one |) //shouldn't need to check this again | _ -> - fail g None + fail g (Some t.range) (Printf.sprintf "Could not decide which exists term to eliminate: choices are\n%s" (terms_to_string exist_tms)) ) @@ -54,7 +57,9 @@ let check_elim_exists in if not (Tm_ExistsSL? t.t) - then fail g None "elim_exists argument not a Tm_ExistsSL"; + then fail g (Some t.range) + (Printf.sprintf "check_elim_exists: elim_exists argument %s not an existential" + (P.term_to_string t)); let Tm_ExistsSL u { binder_ty=ty } p = t.t in @@ -62,8 +67,10 @@ let check_elim_exists if eq_univ u u' then let x = fresh g in let d = T_ElimExists g u ty p x ty_typing t_typing in - repack (try_frame_pre pre_typing d) post_hint t.range - else fail g None "Universe checking failed in elim_exists" + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint t.range + else fail g (Some t.range) + (Printf.sprintf "check_elim_exists: universe checking failed, computed %s, expected %s" + (P.univ_to_string u') (P.univ_to_string u)) let is_intro_exists_erased (st:st_term) = match st.term with @@ -75,11 +82,14 @@ let check_intro_exists_erased (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { intro_exists_witness_singleton st /\ is_intro_exists_erased st }) (vprop_typing: option (tot_typing g (intro_exists_vprop st) tm_vprop)) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_intro_exists_erased" st.range in + let Tm_IntroExists { p=t; witnesses=[e] } = st.term in let (| t, t_typing |) = match vprop_typing with @@ -88,7 +98,9 @@ let check_intro_exists_erased in if not (Tm_ExistsSL? (t <: term).t) // why this ascription? - then fail g None "elim_exists argument not a Tm_ExistsSL"; + then fail g (Some st.range) + (Printf.sprintf "check_intro_exists_erased: vprop %s is not an existential" + (P.term_to_string t)); let Tm_ExistsSL u b p = (t <: term).t in @@ -97,18 +109,21 @@ let check_intro_exists_erased let (| e, e_typing |) = check_term_with_expected_type g e (mk_erased u b.binder_ty) in let d = T_IntroExistsErased g u b p e ty_typing t_typing (E e_typing) in - repack (try_frame_pre pre_typing d) post_hint (t <: term).range + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint (t <: term).range let check_intro_exists_non_erased (g:env) (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { intro_exists_witness_singleton st /\ not (is_intro_exists_erased st) }) (vprop_typing: option (tot_typing g (intro_exists_vprop st) tm_vprop)) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_intro_exists_non_erased" st.range in + let Tm_IntroExists { p=t; witnesses=[witness] } = st.term in let (| t, t_typing |) = match vprop_typing with @@ -117,7 +132,9 @@ let check_intro_exists_non_erased in if not (Tm_ExistsSL? (t <: term).t) - then fail g None "elim_exists argument not a Tm_ExistsSL"; + then fail g (Some st.range) + (Printf.sprintf "check_intro_exists_non_erased: vprop %s is not an existential" + (P.term_to_string t)); let Tm_ExistsSL u b p = (t <: term).t in @@ -127,18 +144,19 @@ let check_intro_exists_non_erased check_term_with_expected_type g witness b.binder_ty in let d = T_IntroExists g u b p witness ty_typing t_typing (E witness_typing) in let (| c, d |) : (c:_ & st_typing g _ c) = (| _, d |) in - repack (try_frame_pre pre_typing d) post_hint (t <: term).range + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint (t <: term).range let check_intro_exists (g:env) (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { intro_exists_witness_singleton st }) (vprop_typing: option (tot_typing g (intro_exists_vprop st) tm_vprop)) : T.Tac (checker_result_t g pre post_hint) = if is_intro_exists_erased st - then check_intro_exists_erased g pre pre_typing post_hint st vprop_typing - else check_intro_exists_non_erased g pre pre_typing post_hint st vprop_typing + then check_intro_exists_erased g pre pre_typing post_hint res_ppname st vprop_typing + else check_intro_exists_non_erased g pre pre_typing post_hint res_ppname st vprop_typing diff --git a/lib/steel/pulse/Pulse.Checker.Exists.fst.hints b/lib/steel/pulse/Pulse.Checker.Exists.fst.hints index 13eeee74a..4108976b3 100644 --- a/lib/steel/pulse/Pulse.Checker.Exists.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Exists.fst.hints @@ -1,5 +1,5 @@ [ - "x\u0014\u000exJ:A\u0004", + "`WOKT}5(gs3r", [ [ "Pulse.Checker.Exists.check_elim_exists", @@ -16,6 +16,7 @@ "@query", "FStar.List.Tot.Base_interpretation_Tm_arrow_84543425b818e2d10a976186b8e8c250", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "Pulse.Syntax.Naming_interpretation_Tm_arrow_12fa1b3ed1cc1655dcad602c3f14587a", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", @@ -27,14 +28,14 @@ "constructor_distinct_Pulse.Syntax.Base.Tm_ElimExists", "constructor_distinct_Pulse.Syntax.Base.Tm_ExistsSL", "constructor_distinct_Pulse.Syntax.Base.Tm_VProp", - "data_elim_Pulse.Syntax.Base.Mkppname", "data_elim_Pulse.Syntax.Base.Mkterm", "data_elim_Pulse.Syntax.Base.Tm_ExistsSL", "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_FStar.Pervasives.Native.Some", "disc_equation_Pulse.Syntax.Base.C_Tot", "disc_equation_Pulse.Syntax.Base.Tm_ElimExists", "disc_equation_Pulse.Syntax.Base.Tm_ExistsSL", "eq2-interp", - "equation_FStar.Range.range", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", @@ -47,29 +48,36 @@ "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.as_binder", "equation_Pulse.Typing.comp_elim_exists", + "equation_Pulse.Typing.post_hint_opt", "equation_with_fuel_FStar.List.Tot.Base.memP.fuel_instrumented", "equation_with_fuel_Pulse.Elaborate.Pure.elab_term.fuel_instrumented", + "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", "function_token_typing_Prims.string", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", "interpretation_Tm_abs_ece6ee511cdff34d3d8f34a2f54bda3e", - "kinding_Pulse.Syntax.Base.term@tok", "l_or-interp", + "kinding_Pulse.Syntax.Base.term@tok", + "kinding_Pulse.Typing.post_hint_t@tok", "l_or-interp", "lemma_FStar.List.Tot.Base.mem_filter_forall", "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Pervasives.invertOption", "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_Pulse.Syntax.Base.range_singleton", "primitive_Prims.op_Negation", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_Pulse.Syntax.Base.Mkbinder_binder_ppname", "proj_equation_Pulse.Syntax.Base.Mkbinder_binder_ty", "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkppname_range", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Syntax.Base.Mkterm_range", "proj_equation_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_FStar.Tactics.Result.Failed_a", "projection_inverse_FStar.Tactics.Result.Failed_exn", @@ -97,24 +105,29 @@ "refinement_interpretation_Tm_refine_5a00527e4107015a0b877b7f48d80006", "refinement_interpretation_Tm_refine_5c77e54d118aa26696ff018c647e0d2c", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_aba97c1b97d7339b3a9a18ebda5655ae", + "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "string_typing", "typing_FStar.List.Tot.Base.filter", - "typing_FStar.Range.range_0", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.mem", "typing_Pulse.RuntimeUtils.union_ranges", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.RuntimeUtils.union_ranges", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t", "typing_Pulse.Syntax.Base.eq_univ", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Base.tm_exists_sl", - "typing_Pulse.Syntax.Base.uu___is_Tm_ExistsSL", "typing_Pulse.Typing.Combinators.vprop_as_list", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.as_binder", + "typing_Pulse.Typing.Env.fresh", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context", + "typing_Pulse.Typing.as_binder", "typing_Tm_abs_ece6ee511cdff34d3d8f34a2f54bda3e" ], 0, - "10ae371e0fc12eb6e2cd0f80335d24cc" + "d96131047ebbe8463fd4b03aa0370570" ], [ "Pulse.Checker.Exists.intro_exists_vprop", @@ -126,7 +139,7 @@ "refinement_interpretation_Tm_refine_2e3881200c03c5d6a5e08c8400580303" ], 0, - "356a063c9ad93b896ca27eb256d031e0" + "f507dd4d5ebcc0d7806b5604697dce06" ], [ "Pulse.Checker.Exists.check_intro_exists_erased", @@ -139,7 +152,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "ebd746b46e34c0db4f73227090c9e625" + "3fc795007d36017eb6c8ded4e94354d4" ], [ "Pulse.Checker.Exists.check_intro_exists_erased", @@ -161,9 +174,9 @@ "constructor_distinct_Pulse.Syntax.Base.Tm_ExistsSL", "constructor_distinct_Pulse.Syntax.Base.Tm_VProp", "data_elim_Pulse.Syntax.Base.Mkbinder", + "data_elim_Pulse.Syntax.Base.Mkppname", "data_elim_Pulse.Syntax.Base.Mkterm", "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_FStar.Pervasives.Native.Some", "disc_equation_Prims.Cons", "disc_equation_Prims.Nil", "disc_equation_Pulse.Syntax.Base.C_Tot", "disc_equation_Pulse.Syntax.Base.Tm_ExistsSL", @@ -171,11 +184,8 @@ "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.Typing.pp_name_t", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Sealed.Inhabited.is_sealed", - "equation_FStar.Sealed.Inhabited.sealed", - "equation_FStar.Sealed.Inhabited.sealed_", "equation_Prims.eqtype", - "equation_Prims.nat", + "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.subset", + "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Exists.intro_exists_vprop", "equation_Pulse.Checker.Exists.intro_exists_witness_singleton", "equation_Pulse.Checker.Exists.is_intro_exists_erased", @@ -190,7 +200,6 @@ "equation_Pulse.Typing.as_binder", "equation_Pulse.Typing.comp_intro_exists_erased", "equation_Pulse.Typing.fresh_wrt", - "equation_Pulse.Typing.tot_typing", "equation_with_fuel_Pulse.Elaborate.Pure.elab_term.fuel_instrumented", "equation_with_fuel_Pulse.Syntax.Naming.freevars.fuel_instrumented", "fuel_guarded_inversion_FStar.Tactics.Result.__result", @@ -212,6 +221,7 @@ "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkppname_range", "proj_equation_Pulse.Syntax.Base.Mkst_term___Tm_IntroExists__payload_witnesses", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Syntax.Base.Mkterm_range", "proj_equation_Pulse.Syntax.Base.Mkterm_t", "proj_equation_Pulse.Syntax.Base.Tm_IntroExists__0", @@ -236,18 +246,15 @@ "projection_inverse_Pulse.Syntax.Base.Tm_ExistsSL_u", "projection_inverse_Pulse.Syntax.Base.Tm_IntroExists__0", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_2e3881200c03c5d6a5e08c8400580303", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_c8d0a5d597a570501a950894cb4195e7", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "string_typing", "token_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", - "true_interp", "typing_FStar.Range.range_0", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", - "typing_FStar.Set.mem", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", "typing_Pulse.Checker.Exists.intro_exists_vprop", "typing_Pulse.Checker.Exists.intro_exists_witness_singleton", "typing_Pulse.Checker.Exists.is_intro_exists_erased", @@ -256,6 +263,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ty", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t", "typing_Pulse.Syntax.Base.ppname_default", @@ -264,10 +272,11 @@ "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.fresh", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.FV.vars_of_env", "typing_Pulse.Typing.as_binder" ], 0, - "abd76e8764d929c9891520d63140cca8" + "d5961e5d8881e6a1af143f9be2dd465f" ], [ "Pulse.Checker.Exists.check_intro_exists_non_erased", @@ -281,7 +290,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "fbab1f40047c962c4cbe7d6443e54156" + "c012fd73feba49164f0d8db0dfb0de61" ], [ "Pulse.Checker.Exists.check_intro_exists_non_erased", @@ -303,8 +312,8 @@ "constructor_distinct_Pulse.Syntax.Base.Tm_ExistsSL", "constructor_distinct_Pulse.Syntax.Base.Tm_VProp", "data_elim_Pulse.Syntax.Base.Mkbinder", + "data_elim_Pulse.Syntax.Base.Mkppname", "data_elim_Pulse.Syntax.Base.Mkterm", - "data_elim_Pulse.Syntax.Base.Tm_ExistsSL", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Prims.Cons", "disc_equation_Prims.Nil", "disc_equation_Pulse.Syntax.Base.C_Tot", @@ -313,8 +322,8 @@ "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.Typing.pp_name_t", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", - "equation_Prims.nat", + "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.subset", + "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Exists.intro_exists_vprop", "equation_Pulse.Checker.Exists.intro_exists_witness_singleton", "equation_Pulse.Checker.Exists.is_intro_exists_erased", @@ -334,6 +343,7 @@ "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.binder", "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.string", "int_inversion", @@ -349,6 +359,7 @@ "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkppname_range", "proj_equation_Pulse.Syntax.Base.Mkst_term___Tm_IntroExists__payload_witnesses", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Syntax.Base.Mkterm_range", "proj_equation_Pulse.Syntax.Base.Mkterm_t", "proj_equation_Pulse.Syntax.Base.Tm_IntroExists__0", @@ -375,13 +386,12 @@ "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_86ec3569a622cbebb6ace78c4d3bd30b", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "string_typing", "token_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", - "typing_FStar.Range.range_0", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.mem", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", "typing_Pulse.Checker.Exists.intro_exists_witness_singleton", "typing_Pulse.Checker.Exists.is_intro_exists_erased", "typing_Pulse.RuntimeUtils.union_ranges", @@ -389,6 +399,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ty", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t", "typing_Pulse.Syntax.Base.ppname_default", @@ -397,10 +408,11 @@ "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.fresh", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.FV.vars_of_env", "typing_Pulse.Typing.as_binder" ], 0, - "2aecc67c67cdbdfd6fd41d6bdb68d3d9" + "276878c27e079662dad1a15f73c04e70" ], [ "Pulse.Checker.Exists.check_intro_exists", @@ -413,7 +425,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "995d423adda50dba15816f5ae9a6028e" + "2261df3af87ee4d135e32ec21a3f5f9b" ], [ "Pulse.Checker.Exists.check_intro_exists", @@ -426,7 +438,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "561962d0d0bae6cea6238fff226232b4" + "3da1eadf8d9dfeeef190d616408a6bd0" ], [ "Pulse.Checker.Exists.check_intro_exists", @@ -440,7 +452,7 @@ "typing_Pulse.Checker.Exists.intro_exists_witness_singleton" ], 0, - "a67633fecee9b19b2bd55156fa29cf37" + "15be4188968a52180a082de11d6ace23" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Exists.fsti b/lib/steel/pulse/Pulse.Checker.Exists.fsti index 2022cfc17..4f49c27d1 100644 --- a/lib/steel/pulse/Pulse.Checker.Exists.fsti +++ b/lib/steel/pulse/Pulse.Checker.Exists.fsti @@ -11,6 +11,7 @@ val check_elim_exists (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_ElimExists? t.term}) : T.Tac (checker_result_t g pre post_hint) @@ -28,6 +29,7 @@ val check_intro_exists (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { intro_exists_witness_singleton st }) (vprop_typing: option (tot_typing g (intro_exists_vprop st) tm_vprop)) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Exists.fsti.hints b/lib/steel/pulse/Pulse.Checker.Exists.fsti.hints index 1c68e9399..1f8357a3f 100644 --- a/lib/steel/pulse/Pulse.Checker.Exists.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Exists.fsti.hints @@ -1,5 +1,5 @@ [ - "oPAHTBb\u0018j", + "^4\u000eE\u000e\u000bS\u001d", [ [ "Pulse.Checker.Exists.intro_exists_vprop", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_2e3881200c03c5d6a5e08c8400580303" ], 0, - "d08eb23e44148050a7f205d44b26e126" + "de38a09faf676e5941b59665595d1a6c" ], [ "Pulse.Checker.Exists.check_intro_exists", @@ -24,7 +24,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "037b7288d8e14332f384de8baba6ac5c" + "2decdaee2797e4b69f8123f2a92099a8" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.If.fst b/lib/steel/pulse/Pulse.Checker.If.fst index 5d3745f77..62ddfc924 100644 --- a/lib/steel/pulse/Pulse.Checker.If.fst +++ b/lib/steel/pulse/Pulse.Checker.If.fst @@ -8,6 +8,7 @@ open Pulse.Checker.Base open Pulse.Checker.Prover module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer module Metatheory = Pulse.Typing.Metatheory #push-options "--z3rlimit_factor 10 --fuel 0 --ifuel 1" @@ -35,7 +36,10 @@ let rec combine_if_branches | C_STGhost inames1 _, C_STGhost inames2 _ -> if eq_tm inames1 inames2 then (| c_then, e_then_typing, e_else_typing |) - else fail g None "Cannot combine then and else branches (different inames)" + else fail g None + (Printf.sprintf "Cannot combine then and else branches (different inames %s and %s)" + (P.term_to_string inames1) + (P.term_to_string inames2)) | C_ST _, C_STAtomic inames _ -> if eq_tm inames tm_emp_inames then begin @@ -44,7 +48,9 @@ let rec combine_if_branches (Lift_STAtomic_ST g_else c_else) in (| c_then, e_then_typing, e_else_typing |) end - else fail g None "Cannot lift STAtomic else branch to match then" + else fail g None + (Printf.sprintf "Cannot lift STAtomic else branch to match ST then branch, inames %s not empty" + (P.term_to_string inames)) | C_STAtomic inames _, C_ST _ -> if eq_tm inames tm_emp_inames then begin @@ -53,7 +59,9 @@ let rec combine_if_branches (Lift_STAtomic_ST g_then c_then) in (| c_else, e_then_typing, e_else_typing |) end - else fail g None "Cannot lift STAtomic else branch to match then" + else fail g None + (Printf.sprintf "Cannot lift STAtomic then branch to match ST else branch, inames %s not empty" + (P.term_to_string inames)) | C_STGhost _ _, _ -> let w = get_non_informative_witness g_then (comp_u c_then) (comp_res c_then) in let e_then_typing = @@ -66,7 +74,11 @@ let rec combine_if_branches let e_else_typing = T_Lift _ _ _ _ e_else_typing (Lift_STGhost_STAtomic _ _ w) in combine_if_branches _ _ _ e_then_typing _ _ _ e_else_typing - | _, _ -> fail g None "Cannot combine then and else branches (incompatible effects)" + | _, _ -> + fail g None + (Printf.sprintf "Cannot combine then and else branches (incompatible effects %s and %s resp.)" + (P.ctag_to_string (ctag_of_comp_st c_then)) + (P.ctag_to_string (ctag_of_comp_st c_else))) end else fail g None "Cannot combine then and else branches (different st_comp)" #pop-options @@ -77,53 +89,66 @@ let check (pre:term) (pre_typing: tot_typing g pre tm_vprop) (post_hint:post_hint_for_env g) + (res_ppname:ppname) (b:term) (e1 e2:st_term) (check:check_t) : T.Tac (checker_result_t g pre (Some post_hint)) = + let g = Pulse.Typing.Env.push_context g "check_if" e1.range in + let (| b, b_typing |) = check_term_with_expected_type g b tm_bool in let post = post_hint.post in let hyp = fresh g in let g_with_eq (eq_v:term) = - push_binding g hyp ppname_default (mk_eq2 u0 tm_bool b eq_v) + push_binding g hyp (mk_ppname_no_range "_if_hyp") (mk_eq2 u0 tm_bool b eq_v) in - let check_branch (eq_v:term) (br:st_term) + let check_branch (eq_v:term) (br:st_term) (is_then:bool) : T.Tac (br:st_term { ~(hyp `Set.mem` freevars_st br) } & - c:comp { stateful_comp c /\ comp_pre c == pre /\ comp_post_matches_hint c (Some post_hint)} & + c:comp_st { comp_pre c == pre /\ comp_post_matches_hint c (Some post_hint)} & st_typing (g_with_eq eq_v) br c) = let g_with_eq = g_with_eq eq_v in let pre_typing = - Metatheory.tot_typing_weakening1 hyp - (mk_eq2 u0 tm_bool b eq_v) - pre_typing + Metatheory.tot_typing_weakening_single + pre_typing + hyp + (mk_eq2 u0 tm_bool b eq_v) in - let r = check g_with_eq pre pre_typing (Some post_hint) br in - let (| br, c, d |) = apply_checker_result_k r in + + let (| br, c, d |) = + let ppname = mk_ppname_no_range "_if_br" in + let r = + check g_with_eq pre pre_typing (Some post_hint) ppname br in + apply_checker_result_k r ppname in + + let br_name = if is_then then "then" else "else" in if hyp `Set.mem` freevars_st br - then fail g (Some br.range) "Illegal use of control-flow hypothesis in branch" - else if not (stateful_comp c) - then fail g (Some br.range) "Branch computation type not st" + then fail g (Some br.range) + (Printf.sprintf "check_if: branch hypothesis is in freevars of checked %s branch" br_name) else (| br, c, d |) - in + in - let (| e1, c1, e1_typing |) = check_branch tm_true e1 in - let (| e2, c2, e2_typing |) = check_branch tm_false e2 in + let (| e1, c1, e1_typing |) = check_branch tm_true e1 true in + let (| e2, c2, e2_typing |) = check_branch tm_false e2 false in let (| c, e1_typing, e2_typing |) = combine_if_branches _ _ _ e1_typing _ _ _ e2_typing in let c_typing = let x = fresh g in if x `Set.mem` freevars post //exclude this - then fail g None "Unexpected name clash" + then fail g None "Impossible: check_if: unexpected freevar in post, please file a bug-report" else if not (eq_tm (comp_res c) post_hint.ret_ty && eq_univ (comp_u c) post_hint.u && eq_tm (comp_post c) post_hint.post) //exclude by check' strengthening - then fail g None "Unexpected result type in branches" + then fail g None + (Printf.sprintf "check_if: computation type after combining branches does not match post hint,\ + computed: (%s, %s, %s), expected (%s, %s, %s)" + (P.univ_to_string (comp_u c)) (P.term_to_string (comp_res c)) (P.term_to_string (comp_post c)) + (P.univ_to_string post_hint.u) (P.term_to_string post_hint.ret_ty) (P.term_to_string post_hint.post)) else let post_typing = post_hint_typing g post_hint x in intro_comp_typing g c pre_typing post_typing.ty_typing x post_typing.post_typing @@ -132,4 +157,4 @@ let check let d : st_typing_in_ctxt g pre (Some post_hint) = (| _, c, T_If g b e1 e2 c _ hyp (E b_typing) e1_typing e2_typing (E c_typing) |) in - checker_result_for_st_typing d + checker_result_for_st_typing d res_ppname diff --git a/lib/steel/pulse/Pulse.Checker.If.fst.hints b/lib/steel/pulse/Pulse.Checker.If.fst.hints index 8a4776c84..f5efca85b 100644 --- a/lib/steel/pulse/Pulse.Checker.If.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.If.fst.hints @@ -1,5 +1,5 @@ [ - "W\u000b\u00040m\u0006\"", + ")lZ#]Ո_\u000e\u001f;F", [ [ "Pulse.Checker.If.combine_if_branches", @@ -10,12 +10,15 @@ "@MaxIFuel_assumption", "@query", "FStar.Pervasives_interpretation_Tm_arrow_0b6559e6ff3addf84b0c2880affbb335", "Prims_interpretation_Tm_arrow_2eaa01e78f73e9bab5d0955fc1a662da", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Checker.If_interpretation_Tm_arrow_28de09fbc328645c535d32b82f5c72f3", "Pulse.Checker.If_interpretation_Tm_arrow_7d6bcd2fcb58c4c962825c1408309012", "Pulse.Syntax.Base_pretyping_0b425ab385a56835d52cd71c18622a32", "Pulse.Syntax.Base_pretyping_b015b044c5bf00a3dd3df9fa711c87dd", "bool_inversion", "bool_typing", "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_FStar.Tactics.Result.Failed", + "constructor_distinct_FStar.Tactics.Result.Success", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", @@ -85,6 +88,12 @@ "projection_inverse_FStar.Pervasives.Mkdtuple3__3", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_FStar.Tactics.Result.Failed_a", + "projection_inverse_FStar.Tactics.Result.Failed_exn", + "projection_inverse_FStar.Tactics.Result.Failed_ps", + "projection_inverse_FStar.Tactics.Result.Success_a", + "projection_inverse_FStar.Tactics.Result.Success_ps", + "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", @@ -102,7 +111,7 @@ "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "refinement_interpretation_Tm_refine_fcab9cead87b773559d4e1b8bdfab842", "refinement_kinding_Tm_refine_f14e2afd7a235f4fca1d56ac00cdff1a", - "typing_Pulse.Syntax.Base.eq_tm", + "string_typing", "typing_Pulse.Syntax.Base.eq_tm", "typing_Pulse.Syntax.Base.stateful_comp", "typing_Pulse.Syntax.Base.tm_emp_inames", "typing_Pulse.Syntax.Base.uu___is_C_ST", @@ -114,7 +123,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "5f0932bc2bff6223881b745c2250446b" + "11729c0c0a9fcd177f45150622d7079f" ], [ "Pulse.Checker.If.check", @@ -129,7 +138,7 @@ "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384" ], 0, - "a58210dc0aa47f168c2ac1e590438646" + "3ac0d9a4505c285458801b34fbbae11a" ], [ "Pulse.Checker.If.check", @@ -139,26 +148,35 @@ [ "@MaxIFuel_assumption", "@fuel_correspondence_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", - "@query", "Pulse.Typing_pretyping_85b09ae4ef91823fbf549acd09fde244", - "bool_inversion", "bool_typing", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Syntax.Base_pretyping_0b425ab385a56835d52cd71c18622a32", + "Pulse.Typing_pretyping_85b09ae4ef91823fbf549acd09fde244", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", + "data_elim_Pulse.Syntax.Base.Mkppname", "data_elim_Pulse.Typing.Mkpost_hint_t", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", "disc_equation_Pulse.Syntax.Base.C_Tot", + "equality_tok_Pulse.Syntax.Base.Implicit@tok", + "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", + "equation_FStar.Reflection.Typing.pp_name_t", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.comp_u", + "equation_Pulse.Syntax.Base.mk_ppname_no_range", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.st_comp_of_comp", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.typ", @@ -170,20 +188,28 @@ "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.comp_post_matches_hint", - "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.mk_eq2", + "equation_Pulse.Typing.elab_env", "equation_Pulse.Typing.fresh_wrt", + "equation_Pulse.Typing.mk_eq2", "equation_Pulse.Typing.post_hint_for_env", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.tm_bool", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "fuel_guarded_inversion_Pulse.Typing.post_hint_t", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", + "function_token_typing_Prims.string", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.mem_union", + "lemma_Pulse.Syntax.Base.range_singleton", + "lemma_Pulse.Typing.Env.push_binding_bs", "lemma_Pulse.Typing.Env.push_env_as_map", "lemma_Pulse.Typing.post_hint_for_env_extends", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", @@ -200,30 +226,39 @@ "projection_inverse_FStar.Tactics.Result.Failed_a", "projection_inverse_FStar.Tactics.Result.Failed_exn", "projection_inverse_FStar.Tactics.Result.Failed_ps", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_1d91d84778b7937886ecec3dcb0444cd", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_385f59c31213d29cc308b93df5d99dc9", + "refinement_interpretation_Tm_refine_33d567938eec4cdca133070454c31653", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_6ab4588567e3e85899907931d9bf297c", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_853b1e0a397dce148f10bb8160c83223", - "refinement_interpretation_Tm_refine_c3cdd79757da4541443d51d9701d4eac", + "refinement_interpretation_Tm_refine_7c5ff3961efc14619e61d19ec2166b01", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "refinement_interpretation_Tm_refine_f14e2afd7a235f4fca1d56ac00cdff1a", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Syntax.Base.comp_post", + "string_typing", "typing_FStar.Map.contains", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Syntax.Base.comp_u", "typing_Pulse.Syntax.Base.eq_tm", - "typing_Pulse.Syntax.Base.eq_univ", + "typing_Pulse.Syntax.Base.eq_tm", "typing_Pulse.Syntax.Base.eq_univ", + "typing_Pulse.Syntax.Base.mk_ppname_no_range", + "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Naming.freevars_st", "typing_Pulse.Syntax.Pure.u0", "typing_Pulse.Typing.Env.as_map", - "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fresh", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_binding", + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g", - "typing_Pulse.Typing.mk_eq2", "typing_Pulse.Typing.tm_bool" + "typing_Pulse.Typing.mk_eq2", "typing_Pulse.Typing.tm_bool", + "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "e9b2235295bd31d7aeac4846536d4f18" + "32dc683d002fea1a4513197331c77d0f" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.If.fsti b/lib/steel/pulse/Pulse.Checker.If.fsti index 60175e5bb..44aef749f 100644 --- a/lib/steel/pulse/Pulse.Checker.If.fsti +++ b/lib/steel/pulse/Pulse.Checker.If.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing: tot_typing g pre tm_vprop) (post_hint:post_hint_for_env g) + (res_ppname:ppname) (b:term) (e1 e2:st_term) (check:check_t) diff --git a/lib/steel/pulse/Pulse.Checker.If.fsti.hints b/lib/steel/pulse/Pulse.Checker.If.fsti.hints index 5230c26ec..b8138a94e 100644 --- a/lib/steel/pulse/Pulse.Checker.If.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.If.fsti.hints @@ -1,5 +1,5 @@ [ - "0{=L4L$_", + "\u0006=eCp\u000b:dڛ\u00071", [ [ "Pulse.Checker.If.check", @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384" ], 0, - "6ccbd10907301810be79f22120d50257" + "eaddd3d566a9c5e55c916b61233cf651" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.IntroPure.fst b/lib/steel/pulse/Pulse.Checker.IntroPure.fst index 77e7ff40c..77d91a12e 100644 --- a/lib/steel/pulse/Pulse.Checker.IntroPure.fst +++ b/lib/steel/pulse/Pulse.Checker.IntroPure.fst @@ -6,16 +6,23 @@ open Pulse.Checker.Base open Pulse.Checker.Prover module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer let check_prop (g:env) (p:term) : T.Tac (p:term & tot_typing g p tm_prop) = + let p0 = p in let (| p, p_typing |) = Pulse.Checker.Pure.check_vprop g (tm_pure p) in match p.t with | Tm_Pure pp -> let prop_typing = Pulse.Typing.Metatheory.pure_typing_inversion #_ #pp p_typing in (| pp, prop_typing |) - | _ -> fail g None "Unexpected prop" + | _ -> + fail g None + (Printf.sprintf "Impossible: check_intro_pure: checking a pure vprop %s returned a non-pure vprop %s,\ + please file a bug-report" + (P.term_to_string (tm_pure p0)) + (P.term_to_string p)) let check_prop_validity (g:env) (p:term) (typing:tot_typing g p tm_prop): T.Tac (prop_validity g p) = Pulse.Checker.Pure.check_prop_validity g p typing @@ -25,12 +32,15 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_IntroPure? t.term }) : T.Tac (checker_result_t g pre post_hint) = + let g = Pulse.Typing.Env.push_context g "check_intro_pure" t.range in + let Tm_IntroPure { p } = t.term in let (| p, p_typing |) = check_prop g p in let pv = check_prop_validity g p p_typing in let st_typing = T_IntroPure _ _ p_typing pv in - repack (try_frame_pre pre_typing st_typing) post_hint t.range + prove_post_hint (try_frame_pre pre_typing st_typing res_ppname) post_hint t.range diff --git a/lib/steel/pulse/Pulse.Checker.IntroPure.fst.hints b/lib/steel/pulse/Pulse.Checker.IntroPure.fst.hints index c5eb0ccb4..c0744f6ca 100644 --- a/lib/steel/pulse/Pulse.Checker.IntroPure.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.IntroPure.fst.hints @@ -1,5 +1,5 @@ [ - "\u0005\"=&‹\u001d\u000ey", + ">(]Px", [ [ "Pulse.Checker.IntroPure.check_prop", @@ -8,6 +8,7 @@ 1, [ "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", "data_elim_Pulse.Syntax.Base.Mkterm", @@ -26,12 +27,12 @@ "proj_equation_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_Pulse.Syntax.Base.Tm_Pure_p", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "typing_FStar.Reflection.Const.prop_qn", + "string_typing", "typing_FStar.Reflection.Const.prop_qn", "typing_FStar.Reflection.V2.Builtins.pack_fv", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range" ], 0, - "926fe94c7d975d61639c07da38f97976" + "2d055a21eedcb29b12b7c68cb9d5b1a0" ], [ "Pulse.Checker.IntroPure.check", @@ -46,12 +47,17 @@ "disc_equation_Pulse.Syntax.Base.C_Tot", "equation_Pulse.Typing.comp_intro_pure", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.None_a", - "refinement_interpretation_Tm_refine_8cde4c154bce2e51e85181a96461d048" + "refinement_interpretation_Tm_refine_8cde4c154bce2e51e85181a96461d048", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", + "typing_Pulse.Typing.Env.push_context" ], 0, - "995bd1711d62b2428bb0ca9f76713695" + "266ab8203d2452ee1e8f73118d478bab" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.IntroPure.fsti b/lib/steel/pulse/Pulse.Checker.IntroPure.fsti index e461bb66c..a9af5481d 100644 --- a/lib/steel/pulse/Pulse.Checker.IntroPure.fsti +++ b/lib/steel/pulse/Pulse.Checker.IntroPure.fsti @@ -11,5 +11,6 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_IntroPure? t.term }) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.IntroPure.fsti.hints b/lib/steel/pulse/Pulse.Checker.IntroPure.fsti.hints index 3feaf5301..fdf480bf3 100644 --- a/lib/steel/pulse/Pulse.Checker.IntroPure.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.IntroPure.fsti.hints @@ -1 +1 @@ -[ "\u000fC,3\nJ\u0012CN1", [] ] \ No newline at end of file +[ "IL\tC\u0014", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Match.fst b/lib/steel/pulse/Pulse.Checker.Match.fst index 507de5ccf..c33f5ff74 100644 --- a/lib/steel/pulse/Pulse.Checker.Match.fst +++ b/lib/steel/pulse/Pulse.Checker.Match.fst @@ -165,7 +165,7 @@ let rec tot_typing_weakening_n bs d = match bs with | [] -> d | (x,t)::bs -> - let d = Pulse.Typing.Metatheory.tot_typing_weakening1 x t d in + let d = Pulse.Typing.Metatheory.tot_typing_weakening_single d x t in tot_typing_weakening_n bs d let samepat (b1 b2 : branch) : prop = fst b1 == fst b2 @@ -231,13 +231,12 @@ let check_branch let g' = push_binding g' hyp_var ({name = Sealed.seal "branch equality"; range = Range.range_0 }) eq_typ in let e = open_st_term_bs e pulse_bs in let pre_typing = tot_typing_weakening_n pulse_bs pre_typing in // weaken w/ binders - let pre_typing = Pulse.Typing.Metatheory.tot_typing_weakening1 hyp_var eq_typ pre_typing in // weaken w/ branch eq + let pre_typing = Pulse.Typing.Metatheory.tot_typing_weakening_single pre_typing hyp_var eq_typ in // weaken w/ branch eq let (| e, c, e_d |) = - let r = check g' pre pre_typing (Some post_hint) e in - apply_checker_result_k r in - if not (stateful_comp c) then - fail g (Some e.range) "Branch computation is not stateful"; + let ppname = mk_ppname_no_range "_br" in + let r = check g' pre pre_typing (Some post_hint) ppname e in + apply_checker_result_k r ppname in let br_d : br_typing g sc_u sc_ty sc p (close_st_term_n e (L.map fst pulse_bs)) c = TBR g sc_u sc_ty sc c p e bs () () () hyp_var e_d in (| p, close_st_term_n e (L.map fst pulse_bs), c, br_d |) @@ -295,11 +294,15 @@ let check (pre:term) (pre_typing: tot_typing g pre tm_vprop) (post_hint:post_hint_for_env g) + (res_ppname:ppname) (sc:term) (brs:list branch) (check:check_t) : T.Tac (checker_result_t g pre (Some post_hint)) = + + let g = Pulse.Typing.Env.push_context_no_range g "check_match" in + let sc_range = sc.range in // save range, it gets lost otherwise let orig_brs = brs in let nbr = L.length brs in @@ -346,4 +349,4 @@ let check assume (L.map (fun (p, _) -> elab_pat p) brs == elab_pats'); let d = T_Match g sc_u sc_ty sc sc_ty_typing (E sc_typing) c brs brs_d complete_d in - checker_result_for_st_typing (| _, _, d |) + checker_result_for_st_typing (| _, _, d |) res_ppname diff --git a/lib/steel/pulse/Pulse.Checker.Match.fst.hints b/lib/steel/pulse/Pulse.Checker.Match.fst.hints index a5144abb3..fa20fa5f8 100644 --- a/lib/steel/pulse/Pulse.Checker.Match.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Match.fst.hints @@ -1,5 +1,5 @@ [ - "\u000e!C,CkP\\\u0012!", + "\u0003R(y\b&5˝\u0005S", [ [ "Pulse.Checker.Match.readback_pat", @@ -21,7 +21,7 @@ "subterm_ordering_FStar.Reflection.V2.Data.Pat_Cons", "true_interp" ], 0, - "01f2a862232502ec63810ddda012aa40" + "5bb9a6890350917cbfd83c6aacd9e840" ], [ "Pulse.Checker.Match.readback_pat", @@ -727,19 +727,15 @@ "disc_equation_Prims.Cons", "disc_equation_Prims.Nil", "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.freshv", + "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.freshv", "equation_with_fuel_Pulse.Typing.all_fresh.fuel_instrumented", "equation_with_fuel_Pulse.Typing.push_bindings.fuel_instrumented", "fuel_guarded_inversion_Prims.list", - "function_token_typing_Prims.__cache_version_number__", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "l_and-interp", "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Set.mem_empty", + "kinding_Pulse.Syntax.Base.term@tok", "l_and-interp", + "lemma_FStar.Map.lemma_ContainsDom", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_BoxBool_proj_0", @@ -748,15 +744,14 @@ "projection_inverse_Prims.Cons_a", "projection_inverse_Prims.Cons_hd", "projection_inverse_Prims.Cons_tl", "projection_inverse_Prims.Nil_a", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_8426dd34ef781f8d75c3a9a4565381e8", "refinement_interpretation_Tm_refine_b57b915c7891c820956facefd0d507fb", "subterm_ordering_Prims.Cons", "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.fstar_env" + "typing_Pulse.Typing.Env.as_map" ], 0, - "8b89889697974f847e6a71803a8d9888" + "8f0b22be3587920f060c132881c74770" ], [ "Pulse.Checker.Match.open_st_term_bs", @@ -774,7 +769,7 @@ "subterm_ordering_Prims.Cons" ], 0, - "9e0cf9264af33b4f85416b8580ca8d26" + "1332080d054c9fb6dabbe0ac9cd165a1" ], [ "Pulse.Checker.Match.r_bindings_to_string", @@ -810,7 +805,6 @@ 1, [ "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_FStar.Reflection.Typing.elaborate_pat.fuel_instrumented", "@fuel_correspondence_Pulse.Checker.Match.readback_pat.fuel_instrumented", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Syntax.Base_pretyping_01e6cbbfeab3ba416b144f2c9223a2d4", @@ -837,8 +831,7 @@ "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Sealed.Inhabited.is_sealed", "equation_FStar.Sealed.Inhabited.sealed", - "equation_FStar.Sealed.Inhabited.sealed_", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.not_tv_unknown", "equation_Pulse.Syntax.Base.ppname_default", @@ -847,19 +840,15 @@ "equation_Pulse.Syntax.Base.tm_vprop", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.with_range", - "equation_Pulse.Typing.Env.binding", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.freshv", + "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.freshv", "equation_Pulse.Typing.post_hint_for_env", "equation_Pulse.Typing.post_hint_for_env_p", "equation_with_fuel_Pulse.Checker.Match.readback_pat.fuel_instrumented", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "fuel_guarded_inversion_Pulse.Typing.post_hint_t", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", @@ -870,7 +859,6 @@ "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", "lemma_FStar.Sealed.Inhabited.sealed_singleton", - "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.mem_empty", "lemma_Pulse.Typing.Env.env_extends_trans", "lemma_Pulse.Typing.post_hint_for_env_extends", "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", @@ -888,7 +876,6 @@ "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_6ab4588567e3e85899907931d9bf297c", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", @@ -896,7 +883,6 @@ "refinement_interpretation_Tm_refine_8f99687fbb0a2aafb98a0035ee7c48ca", "string_typing", "true_interp", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", - "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Checker.Match.readback_pat", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Base.tm_vprop", @@ -906,7 +892,7 @@ "unit_inversion" ], 0, - "36911715668ef4f2a015cae671de4ea3" + "c9eadc59729fcaf9c5fde735158bb906" ], [ "Pulse.Checker.Match.check_branches", @@ -986,7 +972,7 @@ "typing_Tm_abs_485900c7c36cbc1f920d974711c090fd" ], 0, - "f290be5289d1443f5254a5dc94138847" + "17c58d542ff5efb9b78c8c3622f7b8ad" ], [ "Pulse.Checker.Match.check", @@ -1001,7 +987,7 @@ "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384" ], 0, - "0f7256138aeadd9f63b86ab3eec4c837" + "4ed8f26749676901e5ff103e961d7aa7" ], [ "Pulse.Checker.Match.check", @@ -1078,20 +1064,23 @@ "projection_inverse_FStar.Tactics.Result.Success_a", "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", - "refinement_interpretation_Tm_refine_17c22d590fab50a4953743842033211e", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_58f5570aac197f241bcbabc5b2e5bc47", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_8a241246dda1c21254b790029e39c04c", - "refinement_kinding_Tm_refine_17c22d590fab50a4953743842033211e", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "refinement_interpretation_Tm_refine_fa658e1cf17c0e65d4176b9b170d129b", + "refinement_kinding_Tm_refine_fa658e1cf17c0e65d4176b9b170d129b", + "string_typing", "token_correspondence_FStar.List.Tot.Base.length.fuel_instrumented", "typing_Pulse.Common.map_opt", "typing_Pulse.Common.zip", - "typing_Pulse.Typing.Env.fstar_env" + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_context_no_range" ], 0, - "50101b38d7ae59248b0fa5add992b1bc" + "f5590fb59b8141f96077d6061250954e" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Match.fsti b/lib/steel/pulse/Pulse.Checker.Match.fsti index e19183861..efb8bb36e 100644 --- a/lib/steel/pulse/Pulse.Checker.Match.fsti +++ b/lib/steel/pulse/Pulse.Checker.Match.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing: tot_typing g pre tm_vprop) (post_hint:post_hint_for_env g) + (res_ppname:ppname) (sc:term) (brs:list branch) (check:check_t) diff --git a/lib/steel/pulse/Pulse.Checker.Match.fsti.hints b/lib/steel/pulse/Pulse.Checker.Match.fsti.hints index 9f00e43f8..b3628b464 100644 --- a/lib/steel/pulse/Pulse.Checker.Match.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Match.fsti.hints @@ -1,5 +1,5 @@ [ - "(\u000e\t\u0015K&~\u000eU0L", + "-I(R&0CYWr", [ [ "Pulse.Checker.Match.check", @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384" ], 0, - "2efbce58a4333d1a1e62c5448b6f24e9" + "ef1ca511aa98a304fe0656e34d4a419e" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Par.fst b/lib/steel/pulse/Pulse.Checker.Par.fst index c94d12217..90bdc7626 100644 --- a/lib/steel/pulse/Pulse.Checker.Par.fst +++ b/lib/steel/pulse/Pulse.Checker.Par.fst @@ -8,6 +8,7 @@ open Pulse.Checker.Prover open Pulse.Checker.Comp module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer module RT = FStar.Reflection.Typing module MT = Pulse.Typing.Metatheory @@ -16,6 +17,7 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_Par? t.term}) (check:check_t) : T.Tac (checker_result_t g pre post_hint) = @@ -31,24 +33,28 @@ let check let postL_hint = intro_post_hint g None None postL in let (| eL, cL, eL_typing |) = + let ppname = mk_ppname_no_range "_par_l" in let r = - check g preL (E preL_typing) (Some postL_hint) eL in - apply_checker_result_k r in + check g preL (E preL_typing) (Some postL_hint) ppname eL in + apply_checker_result_k r ppname in if C_ST? cL then let cL_typing = MT.st_typing_correctness eL_typing in let postR_hint = intro_post_hint g None None postR in let (| eR, cR, eR_typing |) = - let r = - check g preR (E preR_typing) (Some postR_hint) eR in - apply_checker_result_k r in + let ppname = mk_ppname_no_range "_par_r" in + let r = + check g preR (E preR_typing) (Some postR_hint) ppname eR in + apply_checker_result_k r ppname in if C_ST? cR && eq_univ (comp_u cL) (comp_u cR) then let cR_typing = MT.st_typing_correctness eR_typing in let x = fresh g in let d = T_Par _ _ _ _ _ x cL_typing cR_typing eL_typing eR_typing in - repack (try_frame_pre pre_typing d) post_hint t.range - else fail g (Some eR.range) "par: cR is not stt" - else fail g (Some eL.range) "par: cL is not stt" + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint t.range + else fail g (Some eR.range) + (Printf.sprintf "check_par: right computation is not stt (%s)" (P.comp_to_string cR)) + else fail g (Some eL.range) + (Printf.sprintf "check_par: left computation is not stt (%s)" (P.comp_to_string cL)) diff --git a/lib/steel/pulse/Pulse.Checker.Par.fst.hints b/lib/steel/pulse/Pulse.Checker.Par.fst.hints index f35c6a31a..026a62c5b 100644 --- a/lib/steel/pulse/Pulse.Checker.Par.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Par.fst.hints @@ -1,5 +1,5 @@ [ - "=\u0004\u0019\u001aI>!\u0016\n", + "`\b\u001d{7Zy8\t", [ [ "Pulse.Checker.Par.check", @@ -8,15 +8,15 @@ 1, [ "@MaxIFuel_assumption", "@query", - "Pulse.Syntax.Base_pretyping_782a0dad287a00f5de8c110e3ddaeab3", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Typing_pretyping_85b09ae4ef91823fbf549acd09fde244", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.Tm_Par", "data_elim_FStar.Tactics.Result.Success", - "data_elim_Pulse.Syntax.Base.C_ST", "data_elim_Pulse.Typing.Mkpost_hint_t", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", @@ -27,6 +27,7 @@ "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Pure.push_context", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.comp_u", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.typ", @@ -37,7 +38,7 @@ "equation_Pulse.Typing.comp_post_matches_hint", "equation_Pulse.Typing.post_hint_for_env", "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Typing.post_hint_t", "function_token_typing_Prims.__cache_version_number__", @@ -56,22 +57,24 @@ "projection_inverse_FStar.Tactics.Result.Failed_ps", "projection_inverse_Pulse.Syntax.Base.Tm_Par__0", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_385f59c31213d29cc308b93df5d99dc9", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_4778c00f4e85908330c4e5bdc3f06240", - "refinement_interpretation_Tm_refine_5b6c2ff7c20a2b05cf023708098983f8", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", + "refinement_interpretation_Tm_refine_afa7832fbd3a1123d055c3f1bada59fb", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "refinement_interpretation_Tm_refine_fbb0daf4aae9f7caca56062850f20db7", "string_typing", "typing_FStar.Reflection.V2.Data.var", - "typing_Pulse.Checker.Pure.push_context", - "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__u", + "typing_FStar.Set.mem", "typing_Pulse.Checker.Pure.push_context", "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", + "typing_Pulse.Syntax.Base.comp_u", "typing_Pulse.Syntax.Base.eq_univ", "typing_Pulse.Typing.Env.as_map", - "typing_Pulse.Typing.Env.fstar_env" + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env" ], 0, - "6471b1a5dcbc171ca4a183a7fe80da5c" + "9c51ae241fc664c8ba97cac2ec4c0f24" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Par.fsti b/lib/steel/pulse/Pulse.Checker.Par.fsti index ae95216d8..3d307e8d1 100644 --- a/lib/steel/pulse/Pulse.Checker.Par.fsti +++ b/lib/steel/pulse/Pulse.Checker.Par.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_Par? t.term}) (check:check_t) diff --git a/lib/steel/pulse/Pulse.Checker.Par.fsti.hints b/lib/steel/pulse/Pulse.Checker.Par.fsti.hints index df372bf26..7374aaadd 100644 --- a/lib/steel/pulse/Pulse.Checker.Par.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Par.fsti.hints @@ -1 +1 @@ -[ "\u001ba\na\u001b܂\\,", [] ] \ No newline at end of file +[ "/I\u000fon\u001a\u000e", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Base.fst b/lib/steel/pulse/Pulse.Checker.Prover.Base.fst index 0d5a46108..648f4957a 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Base.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.Base.fst @@ -77,8 +77,9 @@ let elim_one (#g:env) let ctxt_frame_typing = star_typing_inversion_l ctxt_frame_p_typing in let x = fresh (push_env g uvs) in + let ppname = mk_ppname_no_range "_pelim" in let k = - continuation_elaborator_with_bind (tm_star ctxt frame) e1_typing ctxt_frame_p_typing x in + continuation_elaborator_with_bind (tm_star ctxt frame) e1_typing ctxt_frame_p_typing (ppname, x) in let g' = push_binding g x nx (comp_res c1) in let ctxt' = tm_star (open_term_nv (comp_post c1) (v_as_nv x)) ctxt in let veq diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Base.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.Base.fst.hints index 583b1ecf5..ad0a9fb7f 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Base.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Base.fst.hints @@ -1,5 +1,5 @@ [ - "\bǵ-i0qB\r", + "\rLS\u00185\u0003^z", [ [ "Pulse.Checker.Prover.Base.list_as_vprop'", @@ -15,7 +15,7 @@ "projection_inverse_BoxBool_proj_0", "subterm_ordering_Prims.Cons" ], 0, - "ef9d6a4fc77cda07d5a624aab66bdb4d" + "0f162211ebbef5abb9703d2893ae6e0b" ], [ "Pulse.Checker.Prover.Base.canon_right_aux", @@ -61,6 +61,7 @@ "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", + "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Pulse.Syntax.Base.C_ST", "constructor_distinct_Pulse.Syntax.Base.C_Tot", "data_elim_Pulse.Syntax.Base.Mkppname", @@ -68,11 +69,16 @@ "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", - "equation_FStar.Pervasives.Native.fst", "equation_FStar.Range.range", + "equation_FStar.Pervasives.Native.fst", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", + "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_FStar.Set.disjoint", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.mk_ppname_no_range", "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.ppname_default", "equation_Pulse.Syntax.Base.range", @@ -90,6 +96,7 @@ "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Typing.st_typing", + "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", "function_token_typing_Prims.string", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", @@ -108,12 +115,14 @@ "lemma_Pulse.Typing.Env.push_env_as_map", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", "proj_equation_Pulse.Syntax.Base.Mkterm_range", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_Pulse.Syntax.Base.C_ST__0", "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", @@ -121,6 +130,8 @@ "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", "projection_inverse_Pulse.Syntax.Base.Mkterm_range", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_26aa72c2bdd0719b051857cb081974bb", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", @@ -131,20 +142,21 @@ "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "string_typing", "typing_FStar.Map.contains", "typing_FStar.Pervasives.Native.fst", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Syntax.Base.ppname_default", + "typing_Pulse.Syntax.Base.mk_ppname_no_range", "typing_Pulse.Syntax.Base.stateful_comp", "typing_Pulse.Syntax.Base.tm_star", "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Typing.Env.as_map", - "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.push_binding", "typing_Pulse.Typing.tm_unit" + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.tm_unit" ], 0, - "dcb6a0d280e53bd6bbda917f3369503b" + "990e75905dad07f40b7fdcce6ecf49cf" ], [ "Pulse.Checker.Prover.Base.elim_all", @@ -202,7 +214,7 @@ "typing_Tm_abs_385ccdcb80169781e0c76efb7f3eeb56" ], 0, - "b35fbea3c5abb27422addab9d016dad1" + "c20fa64b154cecba8b58d0e01cc225e3" ], [ "Pulse.Checker.Prover.Base.add_elims_aux", @@ -265,7 +277,7 @@ "typing_Pulse.Typing.Env.dom" ], 0, - "a317e4d37d3c00f479b8f7fa9773c8d5" + "357455778e7cf2dbddc1a28cb272c01b" ], [ "Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__goals_inv", @@ -293,7 +305,7 @@ "typing_Pulse.Typing.Env.dom" ], 0, - "a0365f679b61f4096c4671e07d7998c7" + "cca4922566adaab67e5fe05dfb5dab35" ], [ "Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__goals_inv", diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Base.fsti.hints b/lib/steel/pulse/Pulse.Checker.Prover.Base.fsti.hints index 95b732814..d74bab304 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Base.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Base.fsti.hints @@ -8,7 +8,7 @@ 1, [ "@query" ], 0, - "ad8390ecca73b5b8bcea2eb818e21b67" + "ae6417558065dfca413d2a676d470085" ], [ "Pulse.Checker.Prover.Base.prover_state", diff --git a/lib/steel/pulse/Pulse.Checker.Prover.ElimExists.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.ElimExists.fst.hints index ed1333827..5b57b793d 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.ElimExists.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.ElimExists.fst.hints @@ -80,7 +80,7 @@ "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.fstar_env" ], 0, - "330f4c3c17c0773b8dbe9d900000f194" + "e8a180715e83f4d8bac3ebc5d8e3f188" ], [ "Pulse.Checker.Prover.ElimExists.elim_exists_frame", @@ -184,7 +184,7 @@ "typing_Pulse.Typing.Env.push_env" ], 0, - "8b5380a8fed634929bda2324af1dd574" + "850e0a0a824d86d62b4864ca6561d03f" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.ElimPure.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.ElimPure.fst.hints index 8dc64dfd0..557b24d7d 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.ElimPure.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.ElimPure.fst.hints @@ -8,7 +8,7 @@ 1, [ "@query", "equation_Pulse.Syntax.Base.range_singleton_trigger" ], 0, - "6ecd570cc0e89619e4b6779a26e5f0ea" + "2843218638d635995129601d8585b1e9" ], [ "Pulse.Checker.Prover.ElimPure.elim_pure_head_typing", @@ -150,7 +150,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t" ], 0, - "0043fca279309b395af7be85f9d9b1d4" + "47b6d38976aff37efce946472f950bf8" ], [ "Pulse.Checker.Prover.ElimPure.elim_pure_frame", @@ -254,7 +254,7 @@ "typing_Pulse.Typing.Env.push_env" ], 0, - "32f0d8f763649bba0cbcd14a448cf33f" + "6a75feadff1f0d34886e3cb84b89c96c" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst b/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst index 2c82cbd86..bc178cd14 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst @@ -37,11 +37,12 @@ let k_intro_exists (#g:env) (#u:universe) (#b:binder) (#p:vprop) let x = fresh g in assume (open_term (comp_post c) x == comp_post c); + let ppname = mk_ppname_no_range "_pintroe" in let k : continuation_elaborator g (frame * subst_term p [ DT 0 e ]) (push_binding g x ppname_default (comp_res c)) (tm_exists_sl u b p * frame) = - continuation_elaborator_with_bind frame t_typing (magic ()) x in + continuation_elaborator_with_bind frame t_typing (magic ()) (ppname, x) in let k : continuation_elaborator @@ -57,7 +58,7 @@ let k_intro_exists (#g:env) (#u:universe) (#b:binder) (#p:vprop) assert (equal (push_env (push_binding g x ppname_default (comp_res c)) empty_env) (push_binding g x ppname_default (comp_res c))); let d1 : st_typing (push_binding g x ppname_default (comp_res c)) t1 c1 = - Pulse.Checker.Prover.Util.st_typing_weakening + Pulse.Typing.Metatheory.st_typing_weakening g empty_env t1 c1 d1 @@ -116,7 +117,7 @@ let intro_exists (#preamble:_) (pst:prover_state preamble) preamble_sub.goals (list_as_vprop [] * pst_sub.solved) = pst_sub.goals_inv in let ropt = PS.ss_to_nt_substs pst_sub.pg pst_sub.uvs pst_sub.ss in - if None? ropt then fail pst_sub.pg None "intro exists ss not well-typed"; + if None? ropt then fail pst_sub.pg None "resulted substitution after intro exists protocol is not well-typed"; // if not (PS.check_well_typedness pst_sub.pg pst_sub.uvs pst_sub.ss) // then fail pst_sub.pg None "intro exists ss not well-typed"; let Some nt = ropt in diff --git a/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst.hints index 74aae4e54..4810570cb 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.IntroExists.fst.hints @@ -1,5 +1,5 @@ [ - "K9'y\u0005Q", + "Nd\u0017ф8<'", [ [ "Pulse.Checker.Prover.IntroExists.coerce_eq", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_0dee8cb03258a67c2f7ec66427696212" ], 0, - "80223cf03a71662970f4dea558bb3d9e" + "dfe23593bac448032508fa4b8a830464" ], [ "Pulse.Checker.Prover.IntroExists.k_intro_exists", @@ -21,7 +21,7 @@ [ "@MaxFuel_assumption", "@MaxIFuel_assumption", "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@query", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", @@ -29,7 +29,9 @@ "constructor_distinct_Prims.Nil", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", "data_elim_Pulse.Syntax.Base.Mkbinder", + "data_elim_Pulse.Syntax.Base.Mkppname", "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_FStar.Pervasives.Native.Some", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", @@ -38,13 +40,19 @@ "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_FStar.Set.disjoint", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Base.continuation_elaborator", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.mk_ppname_no_range", "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.tm_exists_sl", "equation_Pulse.Syntax.Base.typ", @@ -63,14 +71,18 @@ "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.binder", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", + "function_token_typing_Prims.string", "function_token_typing_Pulse.Typing.Env.binding", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", "lemma_FStar.Set.mem_intersect", @@ -85,37 +97,46 @@ "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_Prims.Nil_a", "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_post", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Pervasives.Native.fst", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "string_typing", "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Pervasives.Native.snd", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.comp_res", + "typing_Pulse.Syntax.Base.mk_ppname_no_range", "typing_Pulse.Syntax.Base.stateful_comp", "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.mk_env", + "typing_Pulse.Typing.Env.lookup", "typing_Pulse.Typing.Env.mk_env", "typing_Pulse.Typing.Env.push_binding" ], 0, - "9383f8d7422b0cd9306e343f4feae81d" + "b927a561ea54b24e76540df7fac2c56f" ], [ "Pulse.Checker.Prover.IntroExists.intro_exists", diff --git a/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst b/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst index d1f229066..2c40cc5ba 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst @@ -31,10 +31,11 @@ let k_intro_pure (g:env) (p:term) // p is well-typed in g, so it does not have x free assume (open_term p x == p); + let ppname = mk_ppname_no_range "_pintrop" in let k : continuation_elaborator g (frame * tm_emp) (push_binding g x ppname_default tm_unit) (tm_pure p * frame) = - continuation_elaborator_with_bind frame d (magic ()) x in + continuation_elaborator_with_bind frame d (magic ()) (ppname, x) in let k : continuation_elaborator g frame @@ -260,324 +261,3 @@ let intro_pure (#preamble:_) (pst:prover_state preamble) solved_inv = () } in Some pst_new - - - - - - // // needs lemmas for term forms in Prover.Subst - // assume (pst.ss.(solved_new) == tm_star (tm_pure (pst.ss.(t))) pst.ss.(pst.solved)); - // // pst.ss.(t) is well-typed in pst.pg, we checked above - // assume (freevars (pst.ss.(t)) `Set.subset` dom pst.pg); - - // assert (freevars pst.ss.(solved_new) `Set.subset` dom pst.pg); - - // let pst_new : prover_state preamble = { pst with solved = solved_new; - // unsolved = unsolved_new; - // k; - // goals_inv; - // solved_inv = () } in - - // Some pst_new - -// // // there will be some side conditions related to the typings -// // let k_intro_exists (#g:env) (#u:universe) (#b:binder) (#p:vprop) -// // (ex_typing:tot_typing g (tm_exists_sl u b p) tm_vprop) -// // (#e:term) -// // (e_typing:tot_typing g e b.binder_ty) -// // (#frame:vprop) -// // (frame_typing:tot_typing g frame tm_vprop) -// // : T.Tac (continuation_elaborator g (frame * subst_term p [ DT 0 e ]) -// // g (frame * tm_exists_sl u b p)) = - -// // let t = wr (Tm_IntroExists { erased = false; -// // p = tm_exists_sl u b p; -// // witnesses = [e]; -// // should_check = should_check_true }) in - -// // let c = comp_intro_exists u b p e in - -// // let t_typing = T_IntroExists g u b p e (magic ()) ex_typing e_typing in - -// // assert (comp_pre c == subst_term p [ DT 0 e ]); -// // assert (comp_post c == tm_exists_sl u b p); - -// // let x = fresh g in -// // assume (open_term (comp_post c) x == comp_post c); - -// // let k -// // : continuation_elaborator -// // g (frame * subst_term p [ DT 0 e ]) -// // (push_binding g x ppname_default (comp_res c)) (tm_exists_sl u b p * frame) = -// // continuation_elaborator_with_bind frame t_typing (magic ()) x in - -// // let k -// // : continuation_elaborator -// // g (frame * subst_term p [ DT 0 e ]) -// // (push_binding g x ppname_default (comp_res c)) (frame * tm_exists_sl u b p) = -// // k_elab_equiv k (VE_Refl _ _) (VE_Comm _ _ _) in - -// // fun post_hint r -> -// // let (| t1, c1, d1 |) = r in -// // let d1 : st_typing g t1 c1 = d1 in -// // let empty_env = mk_env (fstar_env g) in -// // assert (equal g (push_env g empty_env)); -// // assert (equal (push_env (push_binding g x ppname_default (comp_res c)) empty_env) -// // (push_binding g x ppname_default (comp_res c))); -// // let d1 : st_typing (push_binding g x ppname_default (comp_res c)) t1 c1 = -// // st_typing_weakening -// // g -// // empty_env -// // t1 c1 d1 -// // (push_binding g x ppname_default (comp_res c)) in - -// // k post_hint (| t1, c1, d1 |) - -// // #push-options "--z3rlimit_factor 4 --ifuel 1 --fuel 1" -// // let intro_exists (#preamble:_) (pst:prover_state preamble) -// // (u:universe) (b:binder) (body:vprop) -// // (unsolved':list vprop) -// // (_:squash (pst.unsolved == (tm_exists_sl u b body)::unsolved')) -// // (prover:prover_t) -// // : T.Tac (pst':prover_state preamble { pst' `pst_extends` pst /\ -// // is_terminal pst' }) = - -// // let x = fresh (push_env pst.pg pst.uvs) in -// // let px = b.binder_ppname, x in -// // let preamble_sub = { -// // g0 = pst.pg; -// // ctxt = list_as_vprop pst.remaining_ctxt; -// // frame = preamble.frame * pst.ss.(pst.solved); -// // ctxt_frame_typing = magic (); -// // goals = open_term_nv body px * (list_as_vprop unsolved'); -// // } in -// // let k_sub: -// // continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst.pg ((list_as_vprop (vprop_as_list preamble_sub.ctxt) * preamble_sub.frame) * pst.ss.(tm_emp)) = -// // let k = k_elab_unit preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) in -// // let k = k_elab_equiv k -// // (VE_Refl _ _) -// // (magic () <: -// // vprop_equiv -// // preamble_sub.g0 -// // (preamble_sub.ctxt * preamble_sub.frame) -// // ((list_as_vprop (vprop_as_list preamble_sub.ctxt) * preamble_sub.frame) * pst.ss.(tm_emp))) in -// // coerce_eq k () -// // in -// // assume (pst.ss.(tm_emp) == tm_emp); -// // let pst_sub : prover_state preamble_sub = { -// // pg = pst.pg; -// // remaining_ctxt = vprop_as_list preamble_sub.ctxt; -// // remaining_ctxt_frame_typing = magic (); -// // uvs = push_binding pst.uvs x b.binder_ppname b.binder_ty; -// // ss = pst.ss; -// // solved = tm_emp; -// // unsolved = (vprop_as_list (open_term_nv body px)) @ unsolved'; -// // k = k_sub; -// // goals_inv = magic (); -// // solved_inv = (); -// // } in -// // let pst_sub = prover pst_sub in -// // let pst_sub_goals_inv -// // : vprop_equiv (push_env pst_sub.pg pst_sub.uvs) -// // preamble_sub.goals -// // (list_as_vprop [] * pst_sub.solved) = pst_sub.goals_inv in -// // let ropt = PS.ss_to_nt_substs pst_sub.pg pst_sub.uvs pst_sub.ss in -// // if None? ropt then fail pst_sub.pg None "intro exists ss not well-typed"; -// // // if not (PS.check_well_typedness pst_sub.pg pst_sub.uvs pst_sub.ss) -// // // then fail pst_sub.pg None "intro exists ss not well-typed"; -// // let Some nt = ropt in -// // assert (PS.well_typed_nt_substs pst_sub.pg pst_sub.uvs nt); -// // let pst_sub_goals_inv -// // : vprop_equiv pst_sub.pg -// // pst_sub.ss.(preamble_sub.goals) -// // pst_sub.ss.(list_as_vprop [] * pst_sub.solved) = -// // PS.vprop_equiv_nt_substs_derived pst_sub.pg pst_sub.uvs pst_sub_goals_inv nt in -// // assume (pst_sub.ss.(list_as_vprop [] * pst_sub.solved) == -// // tm_emp * pst_sub.ss.(pst_sub.solved)); -// // let pst_sub_goals_inv -// // : vprop_equiv pst_sub.pg -// // pst_sub.ss.(preamble_sub.goals) -// // (tm_emp * pst_sub.ss.(pst_sub.solved)) = coerce_eq pst_sub_goals_inv () in -// // let pst_sub_goals_inv -// // : vprop_equiv pst_sub.pg -// // pst_sub.ss.(preamble_sub.goals) -// // pst_sub.ss.(pst_sub.solved) = VE_Trans _ _ _ _ pst_sub_goals_inv (VE_Unit _ _) in -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble_sub.frame) * pst_sub.ss.(pst_sub.solved)) = -// // pst_sub.k in -// // // replacing pst_sub.ss.(pst_sub.solved) with -// // // pst_sub.ss.(preamble_sub.goals) using the equiv relation -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble_sub.frame) * pst_sub.ss.(preamble_sub.goals)) = -// // k_elab_equiv k_sub (VE_Refl _ _) (magic ()) in -// // // substitute preamble_sub.goals -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble_sub.frame) * -// // pst_sub.ss.(open_term_nv body px * (list_as_vprop unsolved'))) = -// // coerce_eq k_sub () in -// // assume (pst_sub.ss.(open_term_nv body px * (list_as_vprop unsolved')) == -// // pst_sub.ss.(open_term_nv body px) * pst_sub.ss.(list_as_vprop unsolved')); -// // let witness = pst_sub.ss.(null_var x) in -// // assume (pst_sub.ss.(open_term_nv body px) == subst_term (pst_sub.ss.(body)) [DT 0 witness]); -// // // rewrite -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble_sub.frame) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness] * pst_sub.ss.(list_as_vprop unsolved'))) = -// // coerce_eq k_sub () in -// // // some * rearrangement -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // preamble_sub.frame * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness])) = -// // k_elab_equiv k_sub (VE_Refl _ _) (magic ()) in - -// // let k_intro_exists -// // : continuation_elaborator -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // preamble_sub.frame * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness])) -// // pst_sub.pg ( _ * -// // (tm_exists_sl u (PS.nt_subst_binder b nt) pst_sub.ss.(body))) = -// // k_intro_exists -// // #pst_sub.pg -// // #u -// // #(PS.nt_subst_binder b nt) -// // #pst_sub.ss.(body) -// // (magic ()) // typing of tm_exists_sl with pst_sub.ss applied -// // #witness -// // (magic ()) // witness typing -// // #_ -// // (magic ()) // frame typing -// // in -// // assume (tm_exists_sl u (PS.nt_subst_binder b nt) pst_sub.ss.(body) == -// // pst_sub.ss.(tm_exists_sl u b body)); -// // // pst_sub.ss extends pst.ss, and pst.ss already solved all of pst.solved -// // assume (pst.ss.(pst.solved) == pst_sub.ss.(pst.solved)); -// // // also substitute preamble_sub.frame -// // let k_intro_exists -// // : continuation_elaborator -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // preamble_sub.frame * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness])) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // (preamble.frame * pst_sub.ss.(pst.solved)) * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (pst_sub.ss.(tm_exists_sl u b body))) = coerce_eq k_intro_exists () in - -// // // rejig some *s in the continuation context -// // let k_intro_exists -// // : continuation_elaborator -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // preamble_sub.frame * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness])) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved) * -// // pst_sub.ss.(tm_exists_sl u b body) * -// // pst_sub.ss.(list_as_vprop unsolved'))) = -// // k_elab_equiv k_intro_exists (VE_Refl _ _) (magic ()) in -// // assume (pst_sub.ss.(pst.solved) * -// // pst_sub.ss.(tm_exists_sl u b body) * -// // pst_sub.ss.(list_as_vprop unsolved') == -// // pst_sub.ss.(pst.solved * tm_exists_sl u b body * list_as_vprop unsolved')); -// // let k_intro_exists -// // : continuation_elaborator -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * -// // preamble_sub.frame * -// // pst_sub.ss.(list_as_vprop unsolved')) * -// // (subst_term (pst_sub.ss.(body)) [DT 0 witness])) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * tm_exists_sl u b body * list_as_vprop unsolved'))) = -// // coerce_eq k_intro_exists () in -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * tm_exists_sl u b body * list_as_vprop unsolved'))) = -// // k_elab_trans k_sub k_intro_exists in -// // // pst.unsolved == tm_exists_sl u b body::unsolved' -// // let k_sub -// // : continuation_elaborator -// // preamble_sub.g0 (preamble_sub.ctxt * preamble_sub.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * list_as_vprop pst.unsolved))) = -// // k_elab_equiv k_sub (VE_Refl _ _) (magic ()) in - -// // let k_sub -// // : continuation_elaborator -// // pst.pg (list_as_vprop pst.remaining_ctxt * (preamble.frame * pst.ss.(pst.solved))) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * list_as_vprop pst.unsolved))) = -// // coerce_eq k_sub () in - -// // // rejig *s in the elab ctxt -// // let k_sub -// // : continuation_elaborator -// // pst.pg ((list_as_vprop pst.remaining_ctxt * preamble.frame) * pst.ss.(pst.solved)) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * list_as_vprop pst.unsolved))) = -// // k_elab_equiv k_sub (magic ()) (VE_Refl _ _) in - -// // let k -// // : continuation_elaborator -// // preamble.g0 (preamble.ctxt * preamble.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(pst.solved * list_as_vprop pst.unsolved))) = -// // k_elab_trans pst.k k_sub in - -// // let goals_inv -// // : vprop_equiv (push_env pst.pg pst.uvs) -// // preamble.goals -// // (list_as_vprop pst.unsolved * pst.solved) = -// // pst.goals_inv in - -// // // weakening -// // let goals_inv -// // : vprop_equiv (push_env pst_sub.pg pst_sub.uvs) -// // preamble.goals -// // (pst.solved * list_as_vprop pst.unsolved) = magic () in - -// // let goals_inv -// // : vprop_equiv pst_sub.pg -// // (pst_sub.ss.(preamble.goals)) -// // (pst_sub.ss.(pst.solved * list_as_vprop pst.unsolved)) = -// // PS.vprop_equiv_nt_substs_derived pst_sub.pg pst_sub.uvs goals_inv nt in - -// // // rewrite k using goals_inv -// // let k -// // : continuation_elaborator -// // preamble.g0 (preamble.ctxt * preamble.frame) -// // pst_sub.pg ((list_as_vprop pst_sub.remaining_ctxt * preamble.frame) * -// // (pst_sub.ss.(preamble.goals))) = -// // k_elab_equiv k (VE_Refl _ _) (magic ()) in - -// // let pst' : prover_state preamble = { -// // pg = pst_sub.pg; -// // remaining_ctxt = pst_sub.remaining_ctxt; -// // remaining_ctxt_frame_typing = magic (); -// // uvs = pst_sub.uvs; -// // ss = pst_sub.ss; -// // solved = preamble.goals; -// // unsolved = []; -// // k; -// // goals_inv = magic (); -// // solved_inv = magic (); -// // } in - -// // pst' -// // #pop-options diff --git a/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst.hints index 67e04202c..4aaabeceb 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.IntroPure.fst.hints @@ -1,5 +1,5 @@ [ - "\t4ʍ(2ѳ-F", + "IsẐ+]", [ [ "Pulse.Checker.Prover.IntroPure.coerce_eq", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_0dee8cb03258a67c2f7ec66427696212" ], 0, - "f3b91da921ab4efcfaae4c1669817532" + "4e7034b59da66ea1c870db2c6866cec0" ], [ "Pulse.Checker.Prover.IntroPure.k_intro_pure", @@ -23,17 +23,20 @@ "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", "@fuel_correspondence_Pulse.Syntax.Naming.subst_term.fuel_instrumented", "@fuel_irrelevance_Pulse.Syntax.Naming.subst_term.fuel_instrumented", - "@query", "bool_inversion", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Prims.Nil", "constructor_distinct_Pulse.Syntax.Base.C_STGhost", "constructor_distinct_Pulse.Syntax.Base.Tm_Pure", "constructor_distinct_Pulse.Syntax.Base.Tm_VProp", + "data_elim_Pulse.Syntax.Base.Mkppname", "data_typing_intro_Prims.Cons@tok", "data_typing_intro_Prims.Nil@tok", "data_typing_intro_Pulse.Syntax.Naming.DT@tok", "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_FStar.Pervasives.Native.Some", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", @@ -42,15 +45,22 @@ "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_FStar.Set.disjoint", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Base.continuation_elaborator", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.index", + "equation_Pulse.Syntax.Base.mk_ppname_no_range", "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.stateful_comp", "equation_Pulse.Syntax.Base.tm_pure", "equation_Pulse.Syntax.Base.typ", @@ -74,18 +84,23 @@ "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", "equation_with_fuel_Pulse.Syntax.Naming.subst_term.fuel_instrumented", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", + "function_token_typing_Prims.string", "function_token_typing_Pulse.Typing.Env.binding", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", "int_typing", "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Syntax.Naming.subst_elt@tok", "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", "lemma_Pulse.Typing.Env.env_extends_refl", "lemma_Pulse.Typing.Env.equal_elim", @@ -96,6 +111,8 @@ "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", @@ -104,10 +121,11 @@ "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_Prims.Nil_a", "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_post", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", @@ -115,28 +133,33 @@ "projection_inverse_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_Pulse.Syntax.Base.Tm_Pure_p", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Pervasives.Native.fst", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Syntax.Base.comp_res", + "string_typing", "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Pervasives.Native.snd", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", + "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", + "typing_Pulse.Syntax.Base.mk_ppname_no_range", "typing_Pulse.Syntax.Base.tm_pure", "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Syntax.Pure.term_of_nvar", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.mk_env", - "typing_Pulse.Typing.Env.push_binding", - "typing_Pulse.Typing.comp_intro_pure", "typing_Pulse.Typing.tm_unit" + "typing_Pulse.Typing.Env.lookup", + "typing_Pulse.Typing.Env.push_binding", "typing_Pulse.Typing.tm_unit" ], 0, - "b4bfbdb68e29e512ef24ae0c150840c8" + "9fb0ca849079fb10f735b784e87640bd" ], [ "Pulse.Checker.Prover.IntroPure.is_eq2_uvar", @@ -340,7 +363,7 @@ "typing_Pulse.Typing.Env.fstar_env" ], 0, - "edc58bf57b1fa682a28025295bc18b11" + "ea7328e4ceb8025f8fdcc6c175a437b5" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Match.fst b/lib/steel/pulse/Pulse.Checker.Prover.Match.fst index b099c7cf7..fccaa7e8e 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Match.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.Match.fst @@ -156,21 +156,6 @@ let refl_uvar (t:R.term) (uvs:env) : option var = if contains uvs n then Some n else None | _ -> None -// let rec refl_contains_uvar (t:R.term) (uvs:env) (g:env) : T.Tac bool = -// let open R in -// match inspect_ln t with -// | Tv_Var _ -> Some? (refl_uvar t uvs) -// | Tv_BVar _ -// | Tv_FVar _ -// | Tv_UInst _ _ -// | Tv_Const _ -// | Tv_Type _ -> false -// | Tv_App hd (arg, _) -> -// let b = refl_contains_uvar hd uvs g in -// if b then true -// else refl_contains_uvar arg uvs g -// | _ -> fail g None "refl_contains_uvar: unsupported reflection term" - let is_uvar (t:term) (uvs:env) : option var = match t.t with | Tm_FStar t -> refl_uvar t uvs @@ -179,21 +164,6 @@ let is_uvar (t:term) (uvs:env) : option var = let contains_uvar (t:term) (uvs:env) (g:env) : T.Tac bool = not (check_disjoint uvs (freevars t)) - // match t.t with - // | Tm_Emp -> false - // | Tm_Pure p -> contains_uvar p uvs g - // | Tm_Star t1 t2 - // | Tm_ExistsSL _ {binder_ty=t1} t2 - // | Tm_ForallSL _ {binder_ty=t1} t2 -> - // let b = contains_uvar t1 uvs g in - // if b then true - // else contains_uvar t2 uvs g - // | Tm_VProp - // | Tm_Inames - // | Tm_EmpInames -> false - // | Tm_FStar t -> refl_contains_uvar t uvs g - // | Tm_Unknown -> false - let is_reveal_uvar (t:term) (uvs:env) : option (universe & term & var) = match is_pure_app t with | Some (hd, None, arg) -> diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Match.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.Match.fst.hints index 23299438d..015d6a6c0 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Match.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Match.fst.hints @@ -1,5 +1,5 @@ [ - "ʶ\\\u0000|.,;\u000f None + | Some nts -> + let g' = mk_env (fstar_env g) in + assert (equal (push_env uvs g') uvs); + let d = st_typing_nt_substs g uvs g' d nts in + assume (equal (push_env g (nt_subst_env g' nts)) g); + Some d + let st_typing_nt_substs_derived (g:env) (uvs:env { disjoint uvs g }) (#t:st_term) (#c:comp_st) (t_typing:st_typing (push_env g uvs) t c) diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fst.hints index 34528af22..cdfc86d67 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fst.hints @@ -1,5 +1,5 @@ [ - "n=/\u001a}w\fi\u0000\":", + "j\u001cwIiҟ\u001d\u0016&", [ [ "Pulse.Checker.Prover.Substs.coerce_eq", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_0dee8cb03258a67c2f7ec66427696212" ], 0, - "be4323f2fcc3a9cd7560e27d9bac9287" + "549f19b23fce4f76947e815c15575c26" ], [ "Pulse.Checker.Prover.Substs.no_repeats", @@ -27,7 +27,7 @@ "projection_inverse_BoxBool_proj_0", "subterm_ordering_Prims.Cons" ], 0, - "d3ed617e77e7290ecc5d6e42ae0cb8f1" + "3f6671e2536dcc9062a580071c84bd5a" ], [ "Pulse.Checker.Prover.Substs.ss_map", @@ -104,7 +104,7 @@ "typing_Pulse.Syntax.Base.tm_unknown" ], 0, - "b33f1ffa34fe2b458d0e0bddfb91725c" + "84370069cab93e9912d242054efb16bd" ], [ "Pulse.Checker.Prover.Substs.is_dom_mem", @@ -119,7 +119,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "f0099f8aedde3a078dd4a608801e09ab" + "7cf515b2c073335a171b5466d3624a99" ], [ "Pulse.Checker.Prover.Substs.is_dom_mem", @@ -177,7 +177,7 @@ "typing_FStar.Set.union", "typing_Pulse.Syntax.Base.tm_unknown" ], 0, - "465723787c9591e35026a50d20c61a7e" + "54ef09b0d2778e052653e3f350f271a0" ], [ "Pulse.Checker.Prover.Substs.as_map", @@ -564,7 +564,7 @@ "typing_Pulse.Syntax.Base.tm_unknown", "well-founded-ordering-on-nat" ], 0, - "4a2e48875a10538d677187bf5501da8e" + "d1652c6f16e9ae0784578d7e3234a045" ], [ "Pulse.Checker.Prover.Substs.check_disjoint", @@ -690,7 +690,7 @@ "typing_Pulse.Syntax.Base.tm_unknown", "well-founded-ordering-on-nat" ], 0, - "c5f9662a9705c67678203dc6afe9a133" + "e71dd1e62a7829538839a56842be2f08" ], [ "Pulse.Checker.Prover.Substs.remove_l", @@ -729,7 +729,7 @@ "string_typing", "subterm_ordering_Prims.Cons" ], 0, - "85cf194204dd2935dc6a989faf76d1da" + "0106e74fa5aa92baf6127228d8b37573" ], [ "Pulse.Checker.Prover.Substs.is_dom_remove", @@ -763,11 +763,11 @@ "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "primitive_Prims.op_Equality", "primitive_Prims.op_Negation", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_2431b66e19fdfb4c40db2be80082d4ce", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_6c78cd0d452f265d33d4a3b51c7e958e", "refinement_interpretation_Tm_refine_743a26899815015983075ea3d48d9ce0", - "refinement_interpretation_Tm_refine_992888210d3f082580e119e8758107a5", "refinement_interpretation_Tm_refine_be318f37ef272b844b07ed82bd9fff42", "refinement_interpretation_Tm_refine_e9f0f8d04c3ac842acb94e971295cb21", "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", @@ -776,7 +776,7 @@ "typing_FStar.Set.singleton", "typing_Pulse.Syntax.Base.tm_unknown" ], 0, - "ffe47f3adf30b3b0a59f90b076364bf0" + "f35ef41f2929647ed9ce2d620291c541" ], [ "Pulse.Checker.Prover.Substs.is_dom_remove", @@ -886,7 +886,7 @@ "well-founded-ordering-on-nat" ], 0, - "bb364c4b327871b85f76bbe67b39d8dc" + "b4357462ccf40cc790f1c4e5a74687eb" ], [ "Pulse.Checker.Prover.Substs.ss_st_term", @@ -926,7 +926,7 @@ "well-founded-ordering-on-nat" ], 0, - "a0411e4ea6bb63b276589df800246ed8" + "94d0e3196bb95d16e549903e0d944ac5" ], [ "Pulse.Checker.Prover.Substs.ss_st_comp", @@ -966,7 +966,7 @@ "well-founded-ordering-on-nat" ], 0, - "e5ecaa03845e1121eb1439458c284412" + "8011c76db83f95ec257c49500cb6a465" ], [ "Pulse.Checker.Prover.Substs.ss_comp", @@ -1006,7 +1006,7 @@ "well-founded-ordering-on-nat" ], 0, - "a97c0c73a6ea4b642ce46397d5e27a20" + "bd7c24aea9308b84a7c22e8d22207f8b" ], [ "Pulse.Checker.Prover.Substs.ss_binder", @@ -1046,7 +1046,7 @@ "well-founded-ordering-on-nat" ], 0, - "f4e1f8bfed6bad5ee992a76dd4c9dcaf" + "d213612463bf38db901e6c1abd8621cf" ], [ "Pulse.Checker.Prover.Substs.ss_env", @@ -1076,7 +1076,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "f6f4dbfda5e937173425b6700f670845" + "5f9e87c408f8d4fe9ebee8192a728765" ], [ "Pulse.Checker.Prover.Substs.ss_env", @@ -1091,7 +1091,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "0602d54ac6072920aff87fc49d69f5f4" + "9dc19457ceaf7e01e3be30764efde921" ], [ "Pulse.Checker.Prover.Substs.ss_st_comp_commutes", @@ -1180,7 +1180,7 @@ "well-founded-ordering-on-nat" ], 0, - "3eaf9fdea2f8287579fb1725ef347abb" + "4a128b3ea3bfedcb307d0f9b0608c3f4" ], [ "Pulse.Checker.Prover.Substs.ss_comp_commutes", @@ -1210,7 +1210,7 @@ "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0" ], 0, - "8d2e2e0cccdcf31951e788eb6a9a4132" + "1bd1135d3ba316a2f8e36106a1579168" ], [ "Pulse.Checker.Prover.Substs.ss_comp_commutes", @@ -1295,7 +1295,7 @@ "well-founded-ordering-on-nat" ], 0, - "24113bd9307f95dbca18a6a536681e36" + "a0abf09dee8a92345cc05559c5a5affd" ], [ "Pulse.Checker.Prover.Substs.nt_subst_env", @@ -1390,7 +1390,7 @@ "typing_Tm_abs_a710033180f8da1aa5a51a6e77454ded" ], 0, - "63a6656c789b82fa4e155fbad41347c7" + "dc180071413b9b8648cf1eabf319bb9c" ], [ "Pulse.Checker.Prover.Substs.nt_subst_comp_commutes", @@ -1420,7 +1420,7 @@ "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0" ], 0, - "f1b87b2920b1a14e993fa1217924bb81" + "97cadc074dac59d699af0a3bf63df6f1" ], [ "Pulse.Checker.Prover.Substs.nt_subst_comp_commutes", @@ -1475,6 +1475,7 @@ "equation_with_fuel_FStar.List.Tot.Base.memP.fuel_instrumented", "false_interp", "fuel_guarded_inversion_Prims.list", "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", "interpretation_Tm_abs_9221b4287e6d2d711da0e1b1af792f1b", "interpretation_Tm_abs_a3d5dd83fbcf4af6e02dd400fbf0f147", "interpretation_Tm_abs_a710033180f8da1aa5a51a6e77454ded", @@ -1547,7 +1548,7 @@ "typing_FStar.List.Tot.Base.length", "well-founded-ordering-on-nat" ], 0, - "58a93988049687fca435a4bd063d7147" + "4a52474a53d7831fade20b2d20df5e37" ], [ "Pulse.Checker.Prover.Substs.is_permutation", @@ -1613,7 +1614,7 @@ "typing_Pulse.Syntax.Base.tm_unknown" ], 0, - "c010279c80a57e5fd8df320105acb60a" + "125bf474bd515655f0fe39046275f16d" ], [ "Pulse.Checker.Prover.Substs.ss_to_nt_substs", @@ -1694,14 +1695,14 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_523fcfdbd5bea7c684ab12a4989dbd42", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_5d5b629a0cb615e7ec600487bbbc7a10", "refinement_interpretation_Tm_refine_6c78cd0d452f265d33d4a3b51c7e958e", "refinement_interpretation_Tm_refine_743a26899815015983075ea3d48d9ce0", "refinement_interpretation_Tm_refine_98cef3ee6a2061303e53ccf185ee1a01", "refinement_interpretation_Tm_refine_be318f37ef272b844b07ed82bd9fff42", "refinement_interpretation_Tm_refine_e9f0f8d04c3ac842acb94e971295cb21", - "refinement_interpretation_Tm_refine_ec7e07ab087784bd7fe1fed9cd56e934", "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_kinding_Tm_refine_ec7e07ab087784bd7fe1fed9cd56e934", + "refinement_kinding_Tm_refine_5d5b629a0cb615e7ec600487bbbc7a10", "string_typing", "typing_FStar.Map.contains", "typing_FStar.Map.upd", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.complement", "typing_FStar.Set.singleton", @@ -1710,7 +1711,7 @@ "typing_Pulse.Syntax.Base.tm_unknown" ], 0, - "3958ae8590687cd6340d9bdf9b4bae79" + "9af024349188d79f8a535bab5d0a9c76" ], [ "Pulse.Checker.Prover.Substs.well_typed_nt_substs_prefix", @@ -1778,7 +1779,7 @@ "typing_Pulse.Typing.Env.fstar_env", "well-founded-ordering-on-nat" ], 0, - "4a8da3c109a6626ad1d8782498f910b8" + "11131307f53182048df763bb317b4765" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs", @@ -1794,8 +1795,8 @@ "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Set.lemma_equal_elim", @@ -1808,13 +1809,13 @@ "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_a893420d66964b8e290c7368f29b02ca", + "refinement_interpretation_Tm_refine_f7156eab60b4d289049a25ba0b1bb195", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "32f4db0ea8bafca5077cd10de08060c2" + "8e46d4ad02ddcf32f08bf559243ae01e" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs", @@ -1830,8 +1831,8 @@ "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Set.lemma_equal_elim", @@ -1844,13 +1845,13 @@ "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_a893420d66964b8e290c7368f29b02ca", + "refinement_interpretation_Tm_refine_f7156eab60b4d289049a25ba0b1bb195", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "2884286f62bf12aca53971c53f821d2f" + "b9dc5995ce96abacfb633a5eb4aeb90d" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs", @@ -1880,7 +1881,7 @@ "binder_x_1ad99e5433effa849e32ef9adfa111a0_0", "binder_x_1ad99e5433effa849e32ef9adfa111a0_1", "binder_x_4491f3e96d1227aab97069fc644036e1_4", - "binder_x_e0ca80c9d2bca29cf41de2ca31df25fd_2", + "binder_x_7ab694a87fc93464ac8ad15fb6ee914a_2", "binder_x_e646d8345e2cc4469a45893d6bf0973b_6", "bool_inversion", "constructor_distinct_Prims.Cons", "constructor_distinct_Prims.Nil", "constructor_distinct_Pulse.Syntax.Base.C_ST", @@ -1909,9 +1910,9 @@ "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_bindings", "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Metatheory.nt", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.Env.singleton_env", + "equation_Pulse.Typing.Metatheory.Base.nt", "equation_with_fuel_FStar.List.Tot.Base.fold_left.fuel_instrumented", "equation_with_fuel_FStar.List.Tot.Base.length.fuel_instrumented", "equation_with_fuel_FStar.List.Tot.Base.memP.fuel_instrumented", @@ -1924,7 +1925,7 @@ "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Pulse.Typing.Env.binding", "function_token_typing_Pulse.Typing.Env.env", "int_inversion", - "interpretation_Tm_abs_911a4867a8c9f455684310793197d293", + "interpretation_Tm_abs_7cb7d7ad8e9de372eae4aaeb72e37234", "interpretation_Tm_abs_9221b4287e6d2d711da0e1b1af792f1b", "interpretation_Tm_abs_bd6a78e0ce65a0d22871e601c0a470a3", "kinding_Pulse.Syntax.Base.comp@tok", @@ -1957,9 +1958,9 @@ "projection_inverse_Prims.Cons_tl", "projection_inverse_Pulse.Syntax.Naming.NT__1", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_129395affdd8d026c2be2455be50b7e3", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", + "refinement_interpretation_Tm_refine_482eebbc99bd7fd6ae7ea0cc8089952d", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", @@ -1979,14 +1980,129 @@ "typing_Pulse.Typing.Env.mk_env", "typing_Pulse.Typing.Env.push_binding", "typing_Pulse.Typing.Env.push_env", - "typing_Pulse.Typing.Metatheory.subst_env", - "typing_Tm_abs_911a4867a8c9f455684310793197d293", + "typing_Pulse.Typing.Env.subst_env", + "typing_Tm_abs_7cb7d7ad8e9de372eae4aaeb72e37234", "typing_Tm_abs_9221b4287e6d2d711da0e1b1af792f1b", "typing_Tm_abs_bd6a78e0ce65a0d22871e601c0a470a3", "well-founded-ordering-on-nat" ], 0, - "72772148963b5cd8c5061a6f6fc40212" + "85c4950acdeac5f79ee5123f99ef9b3c" + ], + [ + "Pulse.Checker.Prover.Substs.st_typing_subst", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.dom" + ], + 0, + "50435fc7f06c73861766225510d5f9e2" + ], + [ + "Pulse.Checker.Prover.Substs.st_typing_subst", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.dom" + ], + 0, + "ff6a16500550f159bbe212392bd2f2c2" + ], + [ + "Pulse.Checker.Prover.Substs.st_typing_subst", + 3, + 2, + 1, + [ + "@MaxFuel_assumption", "@MaxIFuel_assumption", + "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", + "@fuel_correspondence_Pulse.Checker.Prover.Substs.is_permutation.fuel_instrumented", + "@fuel_correspondence_Pulse.Checker.Prover.Substs.ss_comp.fuel_instrumented", + "@fuel_correspondence_Pulse.Checker.Prover.Substs.ss_st_term.fuel_instrumented", + "@fuel_correspondence_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", + "@fuel_irrelevance_Pulse.Checker.Prover.Substs.is_permutation.fuel_instrumented", + "@fuel_irrelevance_Pulse.Checker.Prover.Substs.ss_comp.fuel_instrumented", + "@fuel_irrelevance_Pulse.Checker.Prover.Substs.ss_st_term.fuel_instrumented", + "@fuel_irrelevance_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", + "@query", "bool_inversion", "constructor_distinct_Prims.Nil", + "data_elim_FStar.Tactics.Result.Success", + "equation_FStar.List.Tot.Base.op_At", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Checker.Prover.Substs.nt_subst_env", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.binding", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.env_bindings", + "equation_Pulse.Typing.Env.equal", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", + "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Pulse.Checker.Prover.Substs.ss_t", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", + "function_token_typing_Pulse.Typing.Env.binding", + "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Checker.Prover.Substs.ss_nt_subst", + "lemma_Pulse.Typing.Env.equal_elim", + "lemma_Pulse.Typing.Env.mk_env_bs", + "lemma_Pulse.Typing.Env.mk_env_dom", + "lemma_Pulse.Typing.Env.push_env_bindings", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "projection_inverse_BoxBool_proj_0", + "projection_inverse_Prims.Nil_a", + "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_5d038f4dc57ccd0fa38b48276342c675", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_a6a90d8166007cc6fd95eef0b29e13af", + "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", + "refinement_kinding_Tm_refine_a6a90d8166007cc6fd95eef0b29e13af", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Checker.Prover.Substs.nt_subst_env", + "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env" + ], + 0, + "58a50afa9a18213680f8376e896b9ec5" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs_derived", @@ -2012,7 +2128,7 @@ "typing_Pulse.Typing.Env.dom" ], 0, - "a9f1adaf401dc8ac36b7cc5d6b3f51be" + "267a94e70f8dfe47178bc3cf9b2e031c" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs_derived", @@ -2059,7 +2175,7 @@ "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_bindings", "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", + "equation_Pulse.Typing.Env.pairwise_disjoint", "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", "function_token_typing_Prims.int", "function_token_typing_Pulse.Typing.Env.binding", @@ -2091,7 +2207,7 @@ "typing_Pulse.Typing.Env.mk_env" ], 0, - "9822960d5d2b5b81f391cfb94795dcd8" + "09ccfa29af4dafadd1b9485de983b152" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti index 6fab9da7d..79b124e1b 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti +++ b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti @@ -5,7 +5,6 @@ open FStar.List.Tot open Pulse.Syntax open Pulse.Typing.Env open Pulse.Typing -open Pulse.Typing.Metatheory module L = FStar.List.Tot module T = FStar.Tactics @@ -137,12 +136,19 @@ val ss_nt_subst (g:env) (uvs:env) (ss:ss_t) (nts:nt_substs) (forall (s:st_comp). nt_subst_st_comp s nts == ss_st_comp s ss)) [SMTPat (well_typed_nt_substs g uvs nts); SMTPat (is_permutation nts ss)] + val st_typing_nt_substs (g:env) (uvs:env) (g':env { pairwise_disjoint g uvs g' }) (#t:st_term) (#c:comp_st) (t_typing:st_typing (push_env g (push_env uvs g')) t c) (ss:nt_substs { well_typed_nt_substs g uvs ss }) : st_typing (push_env g (nt_subst_env g' ss)) (nt_subst_st_term t ss) (nt_subst_comp c ss) +val st_typing_subst (g:env) (uvs:env { disjoint uvs g }) (t:st_term) (c:comp_st) + (d:st_typing (push_env g uvs) t c) + (ss:ss_t) + + : T.Tac (option (st_typing g (ss_st_term t ss) (ss_comp c ss))) + val st_typing_nt_substs_derived (g:env) (uvs:env { disjoint uvs g }) (#t:st_term) (#c:comp_st) (t_typing:st_typing (push_env g uvs) t c) diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti.hints b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti.hints index 21d71a1b3..bb6701395 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Substs.fsti.hints @@ -1,5 +1,5 @@ [ - "nya2\u001es\n", + "RNA\u001fN0", [ [ "Pulse.Checker.Prover.Substs.as_map", @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "63297b0e77b3aeda3e83ff68a26d0dc3" + "525c6fe54c20b834137545b2ad5e1370" ], [ "Pulse.Checker.Prover.Substs.dom", @@ -165,7 +165,7 @@ "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0" ], 0, - "f5d963c7a2d9fb3851c1bbea2c8c34fc" + "3a612a61848757ab4b053997ea4ede71" ], [ "Pulse.Checker.Prover.Substs.well_typed_nt_substs", @@ -199,7 +199,7 @@ "typing_FStar.List.Tot.Base.length", "well-founded-ordering-on-nat" ], 0, - "58a93988049687fca435a4bd063d7147" + "4a52474a53d7831fade20b2d20df5e37" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs", @@ -215,8 +215,8 @@ "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Set.lemma_equal_elim", @@ -229,13 +229,39 @@ "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_a893420d66964b8e290c7368f29b02ca", + "refinement_interpretation_Tm_refine_f7156eab60b4d289049a25ba0b1bb195", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "c44a17d9a77d150e86e8072c99de2810" + "480e14213ed3f275f79dd7883a8780c6" + ], + [ + "Pulse.Checker.Prover.Substs.st_typing_subst", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.dom" + ], + 0, + "1d10966a41102436199052348c20fa24" ], [ "Pulse.Checker.Prover.Substs.st_typing_nt_substs_derived", @@ -261,7 +287,7 @@ "typing_Pulse.Typing.Env.dom" ], 0, - "0106e665cb60497bf7583036a244bced" + "267a94e70f8dfe47178bc3cf9b2e031c" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Util.fst b/lib/steel/pulse/Pulse.Checker.Prover.Util.fst index c56bdefb2..eb3e423dd 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Util.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.Util.fst @@ -1,81 +1,9 @@ module Pulse.Checker.Prover.Util -open Pulse.Syntax -open Pulse.Typing +module RU = Pulse.RuntimeUtils -module T = FStar.Tactics.V2 -module Metatheory = Pulse.Typing.Metatheory -module PS = Pulse.Checker.Prover.Substs - -let st_typing_subst (g:env) (uvs:env { disjoint uvs g }) (t:st_term) (c:comp_st) - (d:st_typing (push_env g uvs) t c) - (ss:PS.ss_t) - - : T.Tac (option (st_typing g (PS.ss_st_term t ss) (PS.ss_comp c ss))) = - - let nts_opt = PS.ss_to_nt_substs g uvs ss in - match nts_opt with - | None -> None - | Some nts -> - let g' = mk_env (fstar_env g) in - assert (equal (push_env uvs g') uvs); - let d = PS.st_typing_nt_substs g uvs g' d nts in - assume (equal (push_env g (PS.nt_subst_env g' nts)) g); - Some d - -let st_typing_weakening - (g:env) (g':env { disjoint g g' }) - (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) - (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) - : st_typing (push_env g1 g') t c = - - let g2 = diff g1 g in - let d = Metatheory.st_typing_weakening g g' t c d g2 in - assert (equal (push_env (push_env g g2) g') (push_env g1 g')); - d - -let st_typing_weakening_standard - (#g:env) (#t:st_term) (#c:comp) (d:st_typing g t c) - (g1:env { g1 `env_extends` g }) - : st_typing g1 t c = - - let g' = mk_env (fstar_env g) in - assert (equal (push_env g g') g); - let d = st_typing_weakening g g' t c d g1 in - assert (equal (push_env g1 g') g1); - d - -let st_typing_weakening_end - (g:env) (g':env { disjoint g g' }) - (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) - (g'':env { g'' `env_extends` g' /\ disjoint g'' g }) - : st_typing (push_env g g'') t c = - - let g2 = diff g'' g' in - let emp_env = mk_env (fstar_env g) in - assert (equal (push_env g g') - (push_env (push_env g g') emp_env)); - let d - : st_typing (push_env (push_env (push_env g g') g2) emp_env) _ _ - = Pulse.Typing.Metatheory.st_typing_weakening (push_env g g') emp_env t c (coerce_eq () d) g2 in - assert (equal (push_env (push_env (push_env g g') g2) emp_env) - (push_env (push_env g g') g2)); - push_env_assoc g g' g2; - assert (equal (push_env (push_env g g') g2) - (push_env g (push_env g' g2))); - assert (equal (push_env g (push_env g' g2)) - (push_env g g'')); - coerce_eq () d - -let veq_weakening - (g:env) (g':env { disjoint g g' }) - (#v1 #v2:vprop) (d:vprop_equiv (push_env g g') v1 v2) - (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) - : vprop_equiv (push_env g1 g') v1 v2 = - - let g2 = diff g1 g in - let d = Metatheory.veq_weakening g g' d g2 in - assert (equal (push_env (push_env g g2) g') (push_env g1 g')); - d - -let debug_prover _ _ = () \ No newline at end of file +let debug_prover g s = + if RU.debug_at_level (fstar_env g) "prover" + then T.print (s ()) + else () + \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Util.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.Util.fst.hints index eae071199..a1717f00b 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Util.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Util.fst.hints @@ -1,327 +1 @@ -[ - "J[۾i\u0012a:\"", - [ - [ - "Pulse.Checker.Prover.Util.st_typing_subst", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom" - ], - 0, - "73902d22ed8fbadd70ce17d0ae417a18" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_subst", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom" - ], - 0, - "582f0e52ddb9e45e4b4b824dd5b43f66" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_subst", - 3, - 2, - 1, - [ - "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@fuel_correspondence_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", - "@fuel_irrelevance_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", - "@query", "bool_inversion", "constructor_distinct_Prims.Nil", - "data_elim_FStar.Tactics.Result.Success", - "equation_FStar.List.Tot.Base.op_At", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Checker.Prover.Substs.nt_subst_env", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.binding", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_bindings", - "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", - "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", - "function_token_typing_Pulse.Typing.Env.binding", - "lemma_FStar.Pervasives.invertOption", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Checker.Prover.Substs.ss_nt_subst", - "lemma_Pulse.Typing.Env.equal_elim", - "lemma_Pulse.Typing.Env.mk_env_bs", - "lemma_Pulse.Typing.Env.mk_env_dom", - "lemma_Pulse.Typing.Env.push_env_bindings", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "projection_inverse_BoxBool_proj_0", - "projection_inverse_Prims.Nil_a", - "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_5d038f4dc57ccd0fa38b48276342c675", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_a6a90d8166007cc6fd95eef0b29e13af", - "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", - "refinement_kinding_Tm_refine_a6a90d8166007cc6fd95eef0b29e13af", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Checker.Prover.Substs.nt_subst_env", - "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env" - ], - 0, - "1bc0bc07c75d9346498ca37d3eb19c9e" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" - ], - 0, - "eab6dc53a4d64395a3a3e8972994adcf" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "97f21315d04c6f5c5fffb2255fa25bb6" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening_standard", - 1, - 2, - 1, - [ - "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@query", "bool_inversion", "constructor_distinct_Prims.Nil", - "equation_FStar.List.Tot.Base.op_At", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.binding", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_bindings", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Env.extends_with", - "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", - "fuel_guarded_inversion_Pulse.Typing.st_typing", - "function_token_typing_Pulse.Typing.Env.binding", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.equal_elim", - "lemma_Pulse.Typing.Env.mk_env_bs", - "lemma_Pulse.Typing.Env.mk_env_dom", - "lemma_Pulse.Typing.Env.push_env_bindings", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "projection_inverse_Prims.Nil_a", - "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env" - ], - 0, - "deb050bbb3989e55dfebdf548a94778d" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening_end", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom" - ], - 0, - "601cdc81bc45bd7b17874b1752ddf511" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening_end", - 2, - 2, - 1, - [ - "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@query", "bool_inversion", "constructor_distinct_Prims.Nil", - "equation_FStar.List.Tot.Base.op_At", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.binding", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_bindings", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", - "fuel_guarded_inversion_Pulse.Typing.st_typing", - "function_token_typing_Pulse.Typing.Env.binding", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.disjoint_not_in_both", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.equal_elim", - "lemma_Pulse.Typing.Env.mk_env_bs", - "lemma_Pulse.Typing.Env.mk_env_dom", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_bindings", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_Prims.Nil_a", - "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", - "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", - "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.mk_env", "typing_Pulse.Typing.Env.push_env" - ], - 0, - "beea4131e119e5f8665333f46daf26ee" - ], - [ - "Pulse.Checker.Prover.Util.veq_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" - ], - 0, - "d52bc6b0cd5b2dd3331057ee14dff608" - ], - [ - "Pulse.Checker.Prover.Util.veq_weakening", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "function_token_typing_Prims.__cache_version_number__", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env" - ], - 0, - "e05a7d5a4a2cf09e17e0a2e9ffa8aaf3" - ] - ] -] \ No newline at end of file +[ "d\bjF\u0014{", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti b/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti index a810b39d6..08919da0b 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti +++ b/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti @@ -6,33 +6,4 @@ open Pulse.Typing module T = FStar.Tactics.V2 module PS = Pulse.Checker.Prover.Substs -val st_typing_subst (g:env) (uvs:env { disjoint uvs g }) (t:st_term) (c:comp_st) - (d:st_typing (push_env g uvs) t c) - (ss:PS.ss_t) - - : T.Tac (option (st_typing g (PS.ss_st_term t ss) (PS.ss_comp c ss))) - -val st_typing_weakening - (g:env) (g':env { disjoint g g' }) - (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) - (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) - : st_typing (push_env g1 g') t c - -val st_typing_weakening_standard - (#g:env) (#t:st_term) (#c:comp) (d:st_typing g t c) - (g1:env { g1 `env_extends` g }) - : st_typing g1 t c - -val st_typing_weakening_end - (g:env) (g':env { disjoint g g' }) - (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) - (g'':env { g'' `env_extends` g' /\ disjoint g'' g }) - : st_typing (push_env g g'') t c - -val veq_weakening - (g:env) (g':env { disjoint g g' }) - (#v1 #v2:vprop) (d:vprop_equiv (push_env g g') v1 v2) - (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) - : vprop_equiv (push_env g1 g') v1 v2 - val debug_prover (g:env) (s:unit -> T.Tac string) : T.Tac unit diff --git a/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti.hints b/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti.hints index 0a1438955..ba787059b 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.Util.fsti.hints @@ -1,78 +1 @@ -[ - "e'GQ\u0001E@\u0003D[{=L};", - [ - [ - "Pulse.Checker.Prover.Util.st_typing_subst", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom" - ], - 0, - "73902d22ed8fbadd70ce17d0ae417a18" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" - ], - 0, - "eab6dc53a4d64395a3a3e8972994adcf" - ], - [ - "Pulse.Checker.Prover.Util.st_typing_weakening_end", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom" - ], - 0, - "9c0ce9cdf798d733a770c4ea1503ffc2" - ], - [ - "Pulse.Checker.Prover.Util.veq_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" - ], - 0, - "10efb8c2aa182dc0d4cdefbb6be637be" - ] - ] -] \ No newline at end of file +[ "޶z`\"b\u0001(\u0003", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.fst b/lib/steel/pulse/Pulse.Checker.Prover.fst index f88024867..ee073742f 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.fst +++ b/lib/steel/pulse/Pulse.Checker.Prover.fst @@ -7,16 +7,18 @@ open Pulse.Typing open Pulse.Typing.Combinators open Pulse.Checker.Base + +module L = FStar.List.Tot +module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer +module Metatheory = Pulse.Typing.Metatheory +module PS = Pulse.Checker.Prover.Substs module ElimExists = Pulse.Checker.Prover.ElimExists module ElimPure = Pulse.Checker.Prover.ElimPure module Match = Pulse.Checker.Prover.Match module IntroExists = Pulse.Checker.Prover.IntroExists module IntroPure = Pulse.Checker.Prover.IntroPure -module L = FStar.List.Tot -module T = FStar.Tactics.V2 -module P = Pulse.Syntax.Printer -module PS = Pulse.Checker.Prover.Substs let coerce_eq (#a #b:Type) (x:a) (_:squash (a == b)) : y:b{y == x} = x @@ -92,14 +94,18 @@ let rec prove_pures #preamble (pst:prover_state preamble) | {t=Tm_Pure p}::unsolved' -> let pst_opt = IntroPure.intro_pure pst p unsolved' () in (match pst_opt with - | None -> fail pst.pg None (Printf.sprintf "cannot prove pure %s\n" (P.term_to_string p)) + | None -> + fail pst.pg None (Printf.sprintf "prover error: cannot prove pure %s\n" (P.term_to_string p)) | Some pst1 -> let pst2 = prove_pures pst1 in assert (pst1 `pst_extends` pst); assert (pst2 `pst_extends` pst1); assert (pst2 `pst_extends` pst); pst2) - | _ -> fail pst.pg None "prove_pures: not a pure" + | _ -> + fail pst.pg None + (Printf.sprintf "Impossible! prover.prove_pures: %s is not a pure, please file a bug-report" + (P.term_to_string (L.hd pst.unsolved))) #push-options "--z3rlimit_factor 4" let rec prover @@ -151,7 +157,14 @@ let rec prover | q::tl -> let pst_opt = match_q pst q tl () 0 in match pst_opt with - | None -> fail pst.pg None "cannot match a vprop" + | None -> + let msg = Printf.sprintf + "cannot prove vprop %s in the context: %s\n(the prover was started with goal %s and initial context %s)" + (P.term_to_string q) + (P.term_to_string (list_as_vprop pst.remaining_ctxt)) + (P.term_to_string preamble.goals) + (P.term_to_string preamble.ctxt) in + fail pst.pg None msg | Some pst -> prover pst // a little wasteful? #pop-options @@ -182,7 +195,7 @@ let prove let ctxt_l = vprop_as_list ctxt in - if Nil? (bindings uvs) && L.existsb (fun v -> eq_tm v goals) ctxt_l + if false && Nil? (bindings uvs) && L.existsb (fun v -> eq_tm v goals) ctxt_l then begin let (| l', d_eq |) = get_q_at_hd g ctxt_l goals in let g1 = g in @@ -222,7 +235,8 @@ let prove let ropt = PS.ss_to_nt_substs pst.pg pst.uvs pst.ss in - if None? ropt then fail pst.pg None "prove: ss not well-typed"; + if None? ropt + then fail pst.pg None "prover error: ill-typed substitutions"; let Some nts = ropt in let nts_uvs = PS.well_typed_nt_substs_prefix pst.pg pst.uvs nts uvs in let k @@ -244,19 +258,22 @@ let prove (| pst.pg, nts_uvs, list_as_vprop pst.remaining_ctxt, k_elab_equiv k (magic ()) (magic ()) |) #pop-options -#push-options "--z3rlimit_factor 4 --fuel 1 --ifuel 1" +#push-options "--z3rlimit_factor 8 --fuel 1 --ifuel 1" let try_frame_pre_uvs (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_vprop) (uvs:env { disjoint g uvs }) (#t:st_term) (#c:comp_st) (d:st_typing (push_env g uvs) t c) + (res_ppname:ppname) : T.Tac (checker_result_t g ctxt None) = + let g = push_context g "try_frame_pre" t.range in + let (| g1, nts, remaining_ctxt, k_frame |) = - prove ctxt_typing uvs #(comp_pre c) (magic ()) in + prove #g #_ ctxt_typing uvs #(comp_pre c) (magic ()) in // assert (nts == []); let d : st_typing (push_env g1 uvs) t c = - Pulse.Checker.Prover.Util.st_typing_weakening g uvs t c d g1 in + Metatheory.st_typing_weakening g uvs t c d g1 in assert (comp_pre (PS.nt_subst_comp c nts) == PS.nt_subst_term (comp_pre c) nts); let t = PS.nt_subst_st_term t nts in @@ -269,16 +286,16 @@ let try_frame_pre_uvs (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_v let x = fresh g1 in let ty = comp_res c in - let g2 = push_binding g1 x ppname_default ty in + let g2 = push_binding g1 x res_ppname ty in assert (g2 `env_extends` g1); - let ctxt' = (open_term_nv (comp_post c) (ppname_default, x) * remaining_ctxt) in + let ctxt' = (open_term_nv (comp_post c) (res_ppname, x) * remaining_ctxt) in - let d : st_typing g1 t c = st_typing_weakening_standard d g1 in + let d : st_typing g1 t c = Metatheory.st_typing_weakening_standard d g1 in let k : continuation_elaborator g1 (remaining_ctxt * comp_pre c) g2 ctxt' = - continuation_elaborator_with_bind remaining_ctxt d (magic ()) x in + continuation_elaborator_with_bind remaining_ctxt d (magic ()) (res_ppname, x) in let k : continuation_elaborator g1 (comp_pre c * remaining_ctxt) @@ -287,40 +304,65 @@ let try_frame_pre_uvs (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_v let k = k_elab_trans k_frame k in - (| x, ty, ctxt', g2, k |) + let comp_res_typing_in_g1, _, f = + Metatheory.st_comp_typing_inversion_cofinite + (Metatheory.comp_typing_inversion (Metatheory.st_typing_correctness d)) in + + let d_ty + : universe_of g2 ty (comp_u c) = + Metatheory.tot_typing_weakening_single comp_res_typing_in_g1 x (comp_res c) in + + assume (~ (x `Set.mem` freevars (comp_post c))); + let d_post + : vprop_typing g2 (open_term_nv (comp_post c) (res_ppname, x)) = + f x in + + // the magic is for the ctxt' typing + // see d_post for post typing + // then the remaining_ctxt typing should come from the prover state + // TODO: add it there + // and then ctxt' is just their `*` + (| x, g2, (| comp_u c, ty, d_ty |), (| ctxt', magic () |), k |) #pop-options let try_frame_pre (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_vprop) - (#t:st_term) (#c:comp_st) (d:st_typing g t c) + (#t:st_term) (#c:comp_st) (d:st_typing g t c) (res_ppname:ppname) : T.Tac (checker_result_t g ctxt None) = let uvs = mk_env (fstar_env g) in assert (equal g (push_env g uvs)); - try_frame_pre_uvs ctxt_typing uvs d + try_frame_pre_uvs ctxt_typing uvs d res_ppname -let repack (#g:env) (#ctxt:vprop) +let prove_post_hint (#g:env) (#ctxt:vprop) (r:checker_result_t g ctxt None) (post_hint:post_hint_opt g) (rng:range) : T.Tac (checker_result_t g ctxt post_hint) = + let g = push_context g "prove_post_hint" rng in + match post_hint with | None -> r | Some post_hint -> - let (| x, ty, ctxt', g2, k |) = r in + let (| x, g2, (| u_ty, ty, ty_typing |), (| ctxt', ctxt'_typing |), k |) = r in - let post_hint_opened = open_term_nv post_hint.post (ppname_default, x) in + let ppname = mk_ppname_no_range "_posth" in + let post_hint_opened = open_term_nv post_hint.post (ppname, x) in // TODO: subtyping if not (eq_tm ty post_hint.ret_ty) - then fail g (Some rng) (Printf.sprintf "result type is not the same in stapp") + then fail g (Some rng) + (Printf.sprintf "error in proving post hint:\ + comp return type %s does not match the post hint %s" + (P.term_to_string ty) + (P.term_to_string post_hint.ret_ty)) else if eq_tm post_hint_opened ctxt' - then (| x, ty, post_hint_opened, g2, k |) + then (| x, g2, (| u_ty, ty, ty_typing |), (| ctxt', ctxt'_typing |), k |) else let (| g3, nts, remaining_ctxt, k_post |) = - prove #g2 #ctxt' (magic ()) (mk_env (fstar_env g2)) #post_hint_opened (magic ()) in + prove #g2 #ctxt' ctxt'_typing (mk_env (fstar_env g2)) #post_hint_opened (magic ()) in assert (nts == []); let k_post @@ -328,9 +370,21 @@ let repack (#g:env) (#ctxt:vprop) coerce_eq k_post () in match check_equiv_emp g3 remaining_ctxt with - | None -> fail g (Some rng) (Printf.sprintf "cannot match post hint in st app") + | None -> + fail g (Some rng) + (Printf.sprintf "error in proving post hint:\ + comp post contains extra vprops not matched in the post hint: %s\n" + (P.term_to_string remaining_ctxt)) | Some d -> let k_post : continuation_elaborator g2 ctxt' g3 post_hint_opened = k_elab_equiv k_post (VE_Refl _ _) (magic ()) in - (| x, ty, post_hint_opened, g3, k_elab_trans k k_post |) + // + // for the typing of ty in g3, + // we have typing of ty in g2 above, and g3 `env_extends` g2 + // + // + // for the typing of post_hint_opened, + // again post_hint is well-typed in g, and g3 `env_extends` g + // + (| x, g3, (| u_ty, ty, magic () |), (| post_hint_opened, magic () |), k_elab_trans k k_post |) diff --git a/lib/steel/pulse/Pulse.Checker.Prover.fst.hints b/lib/steel/pulse/Pulse.Checker.Prover.fst.hints index 6596c2c6b..b4d6b3066 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.fst.hints @@ -1,5 +1,5 @@ [ - "`\u0013Ļ\r~~a`N", + "5.[\beY\r\u001d", [ [ "Pulse.Checker.Prover.coerce_eq", @@ -11,7 +11,7 @@ "refinement_interpretation_Tm_refine_0dee8cb03258a67c2f7ec66427696212" ], 0, - "f92521f9e37383fa2f8d0d4acc471e93" + "76427ae3c19517bf08bca76e842b34e8" ], [ "Pulse.Checker.Prover.unsolved_equiv_pst", @@ -86,7 +86,7 @@ "projection_inverse_BoxBool_proj_0", "subterm_ordering_Prims.Cons" ], 0, - "b93d7d97e969ba05035fd540e8698ab5" + "4548a3915a723ca8bbcbba0627c34153" ], [ "Pulse.Checker.Prover.collect_pures", @@ -105,7 +105,7 @@ "projection_inverse_BoxBool_proj_0", "subterm_ordering_Prims.Cons" ], 0, - "6f1db4ea09ea2ec4747b85a450897fe6" + "8236ff07eebbfda97a0e9ee9b053a25b" ], [ "Pulse.Checker.Prover.match_q", @@ -171,6 +171,9 @@ "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "data_elim_FStar.Tactics.Result.Success", "data_elim_Pulse.Checker.Prover.Base.Mkprover_state", + "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_Prims.Cons", "disc_equation_Prims.Nil", + "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.subset", "equation_Prims.nat", "equation_Pulse.Checker.Prover.Base.is_terminal", @@ -180,11 +183,13 @@ "equation_Pulse.Checker.Prover.Substs.dom", "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.tm_pure", - "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Prims.list", "fuel_guarded_inversion_Pulse.Checker.Prover.Base.prover_state", + "function_token_typing_Prims.__cache_version_number__", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", @@ -194,8 +199,11 @@ "proj_equation_Pulse.Checker.Prover.Base.Mkpreamble_g0", "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_pg", "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_ss", + "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_unsolved", "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_uvs", "proj_equation_Pulse.Syntax.Base.Mkterm_range", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_2fd527fcde0b947169de96ca1a30e30e", "refinement_interpretation_Tm_refine_3201114dc2ece82edbaf3a0633f82db7", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", @@ -207,12 +215,14 @@ "string_typing", "typing_FStar.Reflection.V2.Data.var", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__pg", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__ss", + "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__unsolved", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__uvs", "typing_Pulse.Checker.Prover.Substs.as_map", - "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range" + "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", + "typing_Pulse.Typing.Env.fstar_env" ], 0, - "da208d9b37c683d19cfc6c94f7d89ef5" + "2ee135d6fac0d204a2ee777fd44d5bcf" ], [ "Pulse.Checker.Prover.prover", @@ -225,7 +235,9 @@ "@fuel_correspondence_Pulse.Checker.Prover.collect_exists.fuel_instrumented", "@fuel_correspondence_Pulse.Checker.Prover.collect_pures.fuel_instrumented", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", - "bool_inversion", "constructor_distinct_Prims.Cons", + "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_Prims.Cons", "constructor_distinct_Pulse.Syntax.Base.Tm_ExistsSL", "data_elim_FStar.Tactics.Result.Success", "data_elim_Prims.Cons", "data_elim_Pulse.Checker.Prover.Base.Mkprover_state", @@ -260,7 +272,6 @@ "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.List.Tot.Properties.append_l_nil", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", "lemma_FStar.Set.lemma_equal_elim", @@ -282,6 +293,7 @@ "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Mkdtuple3__1", "projection_inverse_FStar.Pervasives.Mkdtuple3__2", + "projection_inverse_FStar.Pervasives.Mkdtuple3__3", "projection_inverse_Prims.Cons_a", "projection_inverse_Prims.Cons_hd", "projection_inverse_Prims.Cons_tl", @@ -289,6 +301,7 @@ "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_ss", "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_unsolved", "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_uvs", + "projection_inverse_Pulse.Syntax.Base.Mkterm_range", "projection_inverse_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_Pulse.Syntax.Base.Tm_ExistsSL_b", "projection_inverse_Pulse.Syntax.Base.Tm_ExistsSL_body", @@ -326,7 +339,7 @@ "typing_Pulse.Typing.Env.push_env" ], 0, - "a7363ac2777e14a72eb2517eae8ea9d8" + "6900efe21d23f9ebb29c67b4dc6bc7ed" ], [ "Pulse.Checker.Prover.get_q_at_hd", @@ -360,7 +373,7 @@ "typing_Tm_abs_53cd8b855594b9f155c157fb7b929f0e" ], 0, - "6d69e2c71774e6e2b9a87bd72c1afd21" + "a0bc6cc1bfa205dbe763e117e984a156" ], [ "Pulse.Checker.Prover.prove", @@ -378,31 +391,20 @@ 1, [ "@MaxFuel_assumption", "@MaxIFuel_assumption", - "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@fuel_correspondence_FStar.List.Tot.Base.fold_left.fuel_instrumented", - "@fuel_correspondence_FStar.List.Tot.Base.memP.fuel_instrumented", "@fuel_correspondence_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", "@fuel_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", "@fuel_correspondence_Pulse.Typing.Combinators.vprop_as_list.fuel_instrumented", "@fuel_irrelevance_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", - "@query", - "FStar.List.Tot.Base_interpretation_Tm_arrow_f0225aaf6b987d44876e7f498390aa39", - "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", - "Pulse.Checker.Prover.Substs_interpretation_Tm_arrow_75e84b37473765c128ff689d744c8fe4", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", "constructor_distinct_FStar.Tactics.Result.Success", - "constructor_distinct_Prims.Cons", "constructor_distinct_Prims.Nil", "constructor_distinct_Pulse.Syntax.Base.Tm_Emp", "data_elim_FStar.Tactics.Result.Success", - "data_typing_intro_Prims.Nil@tok", "data_typing_intro_Pulse.Checker.Prover.Base.Mkpreamble@tok", "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_Prims.Nil", "equality_tok_Pulse.Syntax.Base.Tm_Emp@tok", - "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", - "equation_FStar.List.Tot.Base.op_At", "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_FStar.Set.subset", @@ -411,33 +413,20 @@ "equation_Pulse.Checker.Prover.Base.op_Array_Access", "equation_Pulse.Checker.Prover.Base.op_Star", "equation_Pulse.Checker.Prover.Base.pst_extends", - "equation_Pulse.Checker.Prover.Substs.nt_subst_term", "equation_Pulse.Syntax.Base.tm_emp", - "equation_Pulse.Syntax.Base.tm_vprop", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Syntax.Base.with_range", - "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_bindings", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", - "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", - "equation_with_fuel_FStar.List.Tot.Base.fold_left.fuel_instrumented", - "equation_with_fuel_FStar.List.Tot.Base.memP.fuel_instrumented", - "equation_with_fuel_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", "equation_with_fuel_Pulse.Syntax.Naming.freevars.fuel_instrumented", - "false_interp", "fuel_guarded_inversion_FStar.Tactics.Result.__result", - "fuel_guarded_inversion_Prims.list", "fuel_guarded_inversion_Pulse.Checker.Prover.Base.prover_state", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", - "function_token_typing_Pulse.Typing.Env.binding", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "kinding_Pulse.Syntax.Naming.subst_elt@tok", - "lemma_FStar.List.Tot.Properties.append_l_nil", + "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Pervasives.invertOption", @@ -458,57 +447,46 @@ "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_solved", "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_ss", "proj_equation_Pulse.Checker.Prover.Base.Mkprover_state_uvs", - "proj_equation_Pulse.Syntax.Base.Mkterm_range", "proj_equation_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Tactics.Result.Failed_a", "projection_inverse_FStar.Tactics.Result.Failed_exn", "projection_inverse_FStar.Tactics.Result.Failed_ps", "projection_inverse_FStar.Tactics.Result.Success_a", "projection_inverse_FStar.Tactics.Result.Success_ps", "projection_inverse_FStar.Tactics.Result.Success_v", - "projection_inverse_Prims.Nil_a", "projection_inverse_Pulse.Checker.Prover.Base.Mkpreamble_ctxt", "projection_inverse_Pulse.Checker.Prover.Base.Mkpreamble_frame", "projection_inverse_Pulse.Checker.Prover.Base.Mkpreamble_g0", "projection_inverse_Pulse.Checker.Prover.Base.Mkpreamble_goals", "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_pg", + "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_solved", "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_ss", "projection_inverse_Pulse.Checker.Prover.Base.Mkprover_state_uvs", - "projection_inverse_Pulse.Syntax.Base.Mkterm_range", "projection_inverse_Pulse.Syntax.Base.Mkterm_t", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_3201114dc2ece82edbaf3a0633f82db7", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_998f5317571047eba4128227bc054984", "refinement_interpretation_Tm_refine_a899d0f0c1a45bdce48dbd70177816ae", "refinement_interpretation_Tm_refine_bbd4dabe4a73e3c0ba415976da2b0b53", "refinement_kinding_Tm_refine_bbd4dabe4a73e3c0ba415976da2b0b53", - "string_typing", "true_interp", + "string_typing", "typing_FStar.Map.domain", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Prims.magic", - "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__pg", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__solved", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__ss", "typing_Pulse.Checker.Prover.Base.__proj__Mkprover_state__item__uvs", "typing_Pulse.Checker.Prover.Base.op_Star", "typing_Pulse.Checker.Prover.Base.vprop_typing", - "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.tm_emp", - "typing_Pulse.Syntax.Base.tm_vprop", - "typing_Pulse.Syntax.Base.with_range", "typing_Pulse.Syntax.Naming.freevars", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", - "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", - "typing_Tm_abs_a710033180f8da1aa5a51a6e77454ded", - "typing_tok_Pulse.Syntax.Base.Tm_Emp@tok", "unit_typing" + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_env", "unit_typing" ], 0, - "80f777227207d7a485c9f05d6add39fa" + "36480e9b0aea59487b37965c46e4a634" ], [ "Pulse.Checker.Prover.try_frame_pre_uvs", @@ -522,7 +500,7 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "3718c34d0f60421c6b50a9e314b3dac6" + "41e15b307d286d48be09b760b387d1ab" ], [ "Pulse.Checker.Prover.try_frame_pre_uvs", @@ -530,10 +508,19 @@ 1, 1, [ - "@MaxIFuel_assumption", "@query", + "@MaxFuel_assumption", "@MaxIFuel_assumption", + "@fuel_correspondence_FStar.List.Tot.Base.fold_left.fuel_instrumented", + "@fuel_correspondence_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", + "@query", + "FStar.List.Tot.Base_interpretation_Tm_arrow_f0225aaf6b987d44876e7f498390aa39", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Checker.Prover.Substs_interpretation_Tm_arrow_44c92d7083e71e4940f9a7025bcacc34", + "Pulse.Checker.Prover.Substs_interpretation_Tm_arrow_4aff1389c612fb274ef6cf645fe0fa4a", + "Pulse.Checker.Prover.Substs_interpretation_Tm_arrow_75e84b37473765c128ff689d744c8fe4", "Pulse.Syntax.Base_pretyping_782a0dad287a00f5de8c110e3ddaeab3", + "Pulse.Syntax.Base_pretyping_b015b044c5bf00a3dd3df9fa711c87dd", "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", - "bool_inversion", "bool_typing", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Pulse.Syntax.Base.C_ST", @@ -542,98 +529,148 @@ "data_elim_Pulse.Syntax.Base.C_ST", "data_elim_Pulse.Syntax.Base.C_STAtomic", "data_elim_Pulse.Syntax.Base.C_STGhost", + "data_elim_Pulse.Syntax.Base.Mkppname", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", "disc_equation_Pulse.Syntax.Base.C_Tot", "equation_FStar.Pervasives.Native.fst", - "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Pervasives.Native.snd", "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", "equation_FStar.Set.disjoint", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", "equation_Pulse.Checker.Base.continuation_elaborator", "equation_Pulse.Checker.Prover.Base.op_Star", "equation_Pulse.Checker.Prover.Substs.nt_subst_comp", + "equation_Pulse.Checker.Prover.Substs.nt_subst_st_comp", + "equation_Pulse.Checker.Prover.Substs.nt_subst_term", + "equation_Pulse.Checker.Prover.Substs.nt_substs", "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.comp_u", "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.st_comp_of_comp", "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Syntax.Base.tm_star", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.universe", "equation_Pulse.Syntax.Base.v_as_nv", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Syntax.Naming.open_term", + "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.extends_with", + "equation_Pulse.Typing.Env.env_bindings", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "equation_with_fuel_FStar.List.Tot.Base.fold_left.fuel_instrumented", + "equation_with_fuel_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", + "false_interp", + "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Prims.list", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", + "function_token_typing_Prims.string", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", + "kinding_Pulse.Syntax.Base.comp@tok", + "kinding_Pulse.Syntax.Base.st_comp@tok", "kinding_Pulse.Syntax.Base.term@tok", + "kinding_Pulse.Syntax.Naming.subst_elt@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomUpd1", "lemma_FStar.Map.lemma_SelUpd1", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Checker.Prover.Substs.nt_subst_comp_commutes", "lemma_Pulse.Checker.Prover.Substs.nt_substs_st_comp_commutes", + "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.env_extends_push", "lemma_Pulse.Typing.Env.env_extends_refl", "lemma_Pulse.Typing.Env.env_extends_trans", "lemma_Pulse.Typing.Env.push_binding_as_map", - "lemma_Pulse.Typing.Env.push_env_as_map", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "primitive_Prims.op_Equality", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", "proj_equation_Pulse.Syntax.Base.Mkst_comp_pre", "proj_equation_Pulse.Syntax.Base.Mkst_comp_res", + "proj_equation_Pulse.Syntax.Base.Mkst_comp_u", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", + "proj_equation_Pulse.Syntax.Base.Mkterm_range", "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Mkdtuple3__2", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", + "projection_inverse_Prims.Mkdtuple2__1", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", "projection_inverse_Pulse.Syntax.Base.C_ST__0", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_post", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_pre", "projection_inverse_Pulse.Syntax.Base.Mkst_comp_res", + "projection_inverse_Pulse.Syntax.Base.Mkst_comp_u", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_12837c1514db76dbfd4a713b928de6cf", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_98cef3ee6a2061303e53ccf185ee1a01", + "refinement_interpretation_Tm_refine_ac147f52608a74d2675e0fe497cebdb9", "refinement_interpretation_Tm_refine_dae521996fd6cc90aa365214b743f248", - "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "string_typing", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Sealed.seal", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Checker.Prover.Substs.nt_subst_comp", "typing_Pulse.Checker.Prover.Substs.nt_subst_term", + "typing_Pulse.RuntimeUtils.union_ranges", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", + "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__post", "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__res", + "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", + "typing_Pulse.Syntax.Base.__proj__Mkterm__item__range", "typing_Pulse.Syntax.Base.comp_res", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Syntax.Base.stateful_comp", - "typing_Pulse.Syntax.Base.uu___is_C_STAtomic", "typing_Pulse.Syntax.Base.uu___is_C_Tot", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.push_binding" + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.lookup", + "typing_Pulse.Typing.Env.push_binding", + "typing_Pulse.Typing.Env.push_context", + "typing_Tm_abs_9221b4287e6d2d711da0e1b1af792f1b", + "typing_Tm_abs_a3d5dd83fbcf4af6e02dd400fbf0f147", + "typing_Tm_abs_a710033180f8da1aa5a51a6e77454ded" ], 0, - "b5857560a75ea9b8dc14652a9925fd4f" + "d797dbcdf55ec8b7194d1cf646528590" ], [ "Pulse.Checker.Prover.try_frame_pre", @@ -647,7 +684,7 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "7259e31cbec27ae7df3d5f9df88520c9" + "9641901fe93453a73975cb5e29d56687" ], [ "Pulse.Checker.Prover.try_frame_pre", @@ -695,10 +732,10 @@ "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env" ], 0, - "bb6d864f66858cb3ea0bf9e357d910d9" + "5dd3658f80f4ab7670985dbf083ff357" ], [ - "Pulse.Checker.Prover.repack", + "Pulse.Checker.Prover.prove_post_hint", 1, 2, 1, @@ -709,10 +746,10 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "c2863c9219bdb60189422de9796f8b0d" + "529ff4c8ea2f7ac3a1f10e1ededaf12b" ], [ - "Pulse.Checker.Prover.repack", + "Pulse.Checker.Prover.prove_post_hint", 2, 2, 1, @@ -726,7 +763,7 @@ "26fe3caa40cb5c05247389edc48c277e" ], [ - "Pulse.Checker.Prover.repack", + "Pulse.Checker.Prover.prove_post_hint", 3, 2, 1, @@ -739,16 +776,29 @@ "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Prims.Cons", "constructor_distinct_Prims.Nil", "data_elim_FStar.Pervasives.Mkdtuple5", + "data_elim_Pulse.Syntax.Base.Mkppname", + "data_typing_intro_FStar.Pervasives.Native.Mktuple2@tok", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_FStar.Pervasives.Native.Some", + "equation_FStar.Pervasives.Native.fst", "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Pervasives.dfst", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", + "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", "equation_Pulse.Checker.Base.checker_result_t", "equation_Pulse.Checker.Base.continuation_elaborator", "equation_Pulse.Checker.Prover.Substs.nt_substs", + "equation_Pulse.Syntax.Base.mk_ppname_no_range", + "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.universe", "equation_Pulse.Syntax.Base.v_as_nv", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Syntax.Base.vprop", "equation_Pulse.Syntax.Naming.open_term", @@ -756,25 +806,32 @@ "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.env_bindings", "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "equation_with_fuel_Pulse.Checker.Prover.Substs.well_typed_nt_substs.fuel_instrumented", - "false_interp", "fuel_guarded_inversion_FStar.Pervasives.dtuple5", + "false_interp", "fuel_guarded_inversion_FStar.Pervasives.dtuple3", + "fuel_guarded_inversion_FStar.Pervasives.dtuple5", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Prims.dtuple2", "fuel_guarded_inversion_Prims.list", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", - "interpretation_Tm_abs_60a5aa96ff1da220b9fe042919aec14c", - "interpretation_Tm_abs_a7c07c7cfa7388d556bc16f9e2978a91", - "interpretation_Tm_abs_edbc06d5ff9cf8ed2ddc9fe1910c602d", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", + "function_token_typing_Prims.string", "int_inversion", + "interpretation_Tm_abs_3c40274298c18b3c60fac0d11fae8431", + "interpretation_Tm_abs_5adeb3a78b1b342e9d9bdc8b1e2ca123", + "interpretation_Tm_abs_e21586ea0dcb2b831fcc0617ea281b2d", + "interpretation_Tm_abs_f9ba06e91f9754038708331844af2d35", + "kinding_Pulse.Syntax.Base.ppname@tok", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "kinding_Pulse.Typing.vprop_equiv@tok", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Map.lemma_SelConcat1", "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", "lemma_FStar.Set.mem_intersect", @@ -785,12 +842,17 @@ "lemma_Pulse.Typing.Env.push_env_fstar_env", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "primitive_Prims.op_Negation", + "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Prims.Mkdtuple2__1", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", "proj_equation_Pulse.Typing.Mkpost_hint_t_post", "proj_equation_Pulse.Typing.Mkpost_hint_t_ret_ty", "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Mkdtuple3__2", "projection_inverse_FStar.Pervasives.Mkdtuple5__1", "projection_inverse_FStar.Pervasives.Mkdtuple5__2", "projection_inverse_FStar.Pervasives.Mkdtuple5__3", @@ -800,30 +862,41 @@ "projection_inverse_FStar.Pervasives.Native.None_a", "projection_inverse_FStar.Pervasives.Native.Some_a", "projection_inverse_FStar.Pervasives.Native.Some_v", - "refinement_interpretation_Tm_refine_0e7cec6ed8f6e8567fd60faa69f1ee6b", + "projection_inverse_Prims.Mkdtuple2__1", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", - "refinement_interpretation_Tm_refine_4e1eb34109a22af0e148292c50322374", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_6d8ee78207eb8c69f5e44f08014b2ba6", + "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", "refinement_interpretation_Tm_refine_98cef3ee6a2061303e53ccf185ee1a01", "refinement_interpretation_Tm_refine_a11f840595aa283ad91d016761d341b9", + "refinement_interpretation_Tm_refine_b0ea3495ff282f69439c9d1354d6b870", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", "refinement_interpretation_Tm_refine_c07455da69b1cf59b5df0a11143d2102", "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "string_typing", "typing_FStar.Map.concat", - "typing_FStar.Map.contains", "typing_FStar.Map.domain", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Map.domain", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Sealed.seal", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Checker.Base.check_equiv_emp", - "typing_Pulse.Syntax.Base.eq_tm", "typing_Pulse.Syntax.Base.tm_emp", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", + "typing_Pulse.Syntax.Base.eq_tm", + "typing_Pulse.Syntax.Base.mk_ppname_no_range", + "typing_Pulse.Syntax.Base.ppname_default", + "typing_Pulse.Syntax.Base.tm_emp", + "typing_Pulse.Syntax.Naming.open_term_nv", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env", + "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__post", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__ret_ty" ], 0, - "b709c05a80ef8d0f69b647ba6a9a6e3d" + "88bd4fffd4df1ebdd762af961f591a3f" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Prover.fsti b/lib/steel/pulse/Pulse.Checker.Prover.fsti index 89f260a95..a554b9c52 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.fsti +++ b/lib/steel/pulse/Pulse.Checker.Prover.fsti @@ -24,15 +24,17 @@ val prove val try_frame_pre_uvs (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_vprop) (uvs:env { disjoint g uvs }) (#t:st_term) (#c:comp_st) (d:st_typing (push_env g uvs) t c) + (res_ppname:ppname) : T.Tac (checker_result_t g ctxt None) val try_frame_pre (#g:env) (#ctxt:vprop) (ctxt_typing:tot_typing g ctxt tm_vprop) (#t:st_term) (#c:comp_st) (d:st_typing g t c) + (res_ppname:ppname) : T.Tac (checker_result_t g ctxt None) -val repack (#g:env) (#ctxt:vprop) +val prove_post_hint (#g:env) (#ctxt:vprop) (r:checker_result_t g ctxt None) (post_hint:post_hint_opt g) (rng:range) diff --git a/lib/steel/pulse/Pulse.Checker.Prover.fsti.hints b/lib/steel/pulse/Pulse.Checker.Prover.fsti.hints index 650be82aa..60425e2ef 100644 --- a/lib/steel/pulse/Pulse.Checker.Prover.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Prover.fsti.hints @@ -1,5 +1,5 @@ [ - "ֲhŜ\u0011N*Q", + "guOO!\n~35", [ [ "Pulse.Checker.Prover.prove", @@ -8,7 +8,7 @@ 1, [ "@query" ], 0, - "b77c51c71d3bf1d9e80d9ee3de1421c8" + "1bbbd96ed10169f69a534435d68f52df" ], [ "Pulse.Checker.Prover.try_frame_pre_uvs", @@ -22,7 +22,7 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "825da332748fbb6c1ed792ca83ecf24f" + "c7ca40ecb3a257f22e47594312ae5979" ], [ "Pulse.Checker.Prover.try_frame_pre", @@ -36,10 +36,10 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "385160c1ccc0e1278675c841fcd7a2f2" + "8f64675045d052042fb0f65986bcd431" ], [ - "Pulse.Checker.Prover.repack", + "Pulse.Checker.Prover.prove_post_hint", 1, 2, 1, @@ -50,7 +50,7 @@ "projection_inverse_FStar.Pervasives.Native.None_a" ], 0, - "c2863c9219bdb60189422de9796f8b0d" + "529ff4c8ea2f7ac3a1f10e1ededaf12b" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Pure.fst.hints b/lib/steel/pulse/Pulse.Checker.Pure.fst.hints index 67baf09e4..8112d3959 100644 --- a/lib/steel/pulse/Pulse.Checker.Pure.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Pure.fst.hints @@ -8,7 +8,7 @@ 1, [ "@query" ], 0, - "ee62f5898de5939921ad35f2c370c4d6" + "57191f73bba6376ce8aa2395b65cf0a6" ], [ "Pulse.Checker.Pure.rtb_core_check_term", diff --git a/lib/steel/pulse/Pulse.Checker.Pure.fsti.hints b/lib/steel/pulse/Pulse.Checker.Pure.fsti.hints index 1030e88bf..fff2147b4 100644 --- a/lib/steel/pulse/Pulse.Checker.Pure.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Pure.fsti.hints @@ -8,7 +8,7 @@ 1, [ "@query" ], 0, - "dfa5e7ddd6d6c3c5c15c103beea8de23" + "116bc0269cda4f59cff6e9196e5793ab" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Return.fst b/lib/steel/pulse/Pulse.Checker.Return.fst index 9423fc795..736007a34 100644 --- a/lib/steel/pulse/Pulse.Checker.Return.fst +++ b/lib/steel/pulse/Pulse.Checker.Return.fst @@ -14,6 +14,7 @@ let check (ctxt:term) (ctxt_typing:tot_typing g ctxt tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { Tm_Return? st.term }) : T.Tac (checker_result_t g ctxt post_hint) = @@ -38,7 +39,7 @@ let check in let x = fresh g in - let px = v_as_nv x in + let px = res_ppname, x in let (| post_opened, post_typing |) : t:term & tot_typing (push_binding g x (fst px) ty) t tm_vprop = match post_hint with | None -> @@ -49,7 +50,9 @@ let check // we already checked for the return type let post : post_hint_t = post in if x `Set.mem` (freevars post.post) - then fail g None "Unexpected variable clash in return" + then fail g None + ("check_return: unexpected variable clash in return post,\ + please file a bug report") else let ty_rec = post_hint_typing g post x in (| open_term_nv post.post px, ty_rec.post_typing |) @@ -57,4 +60,4 @@ let check assume (open_term (close_term post_opened x) x == post_opened); let post = close_term post_opened x in let d = T_Return g c use_eq u ty t post x uty (E d) post_typing in - repack (try_frame_pre ctxt_typing d) post_hint t.range + prove_post_hint (try_frame_pre ctxt_typing d res_ppname) post_hint t.range diff --git a/lib/steel/pulse/Pulse.Checker.Return.fst.hints b/lib/steel/pulse/Pulse.Checker.Return.fst.hints index 264774538..84d4ad231 100644 --- a/lib/steel/pulse/Pulse.Checker.Return.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Return.fst.hints @@ -1,5 +1,5 @@ [ - "\u001c27{\u0015ר_\u000b\u000e_", + "2\u0006-\u0019۝E", [ [ "Pulse.Checker.Return.check", @@ -10,7 +10,7 @@ "@MaxFuel_assumption", "@MaxIFuel_assumption", "@fuel_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", "@fuel_irrelevance_Pulse.Syntax.Naming.freevars.fuel_instrumented", - "@query", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", @@ -22,15 +22,18 @@ "constructor_distinct_Pulse.Syntax.Base.C_STGhost", "constructor_distinct_Pulse.Syntax.Base.STT", "constructor_distinct_Pulse.Syntax.Base.Tm_Return", + "data_elim_Pulse.Syntax.Base.Mkppname", "data_elim_Pulse.Syntax.Base.Mkst_term", "disc_equation_FStar.Pervasives.Native.None", "disc_equation_Pulse.Syntax.Base.C_Tot", "disc_equation_Pulse.Syntax.Base.Tm_Return", "equation_FStar.Pervasives.Native.fst", "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", "equation_Prims.nat", "equation_Pulse.Checker.Pure.push_context", "equation_Pulse.Syntax.Base.index", + "equation_Pulse.Syntax.Base.nvar", "equation_Pulse.Syntax.Base.ppname_default", "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.v_as_nv", @@ -43,27 +46,34 @@ "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.FV.set_minus", "equation_Pulse.Typing.comp_return", - "equation_Pulse.Typing.fresh_wrt", + "equation_Pulse.Typing.elab_env", "equation_Pulse.Typing.fresh_wrt", "equation_Pulse.Typing.post_hint_for_env_p", "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.ctag", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.int", + "function_token_typing_Prims.string", "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "int_typing", "kinding_Pulse.Syntax.Base.term@tok", + "int_typing", "kinding_Pulse.Syntax.Base.ppname@tok", + "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Pervasives.invertOption", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.mem_complement", "lemma_FStar.Set.mem_intersect", "lemma_FStar.Set.mem_singleton", "lemma_Pulse.Syntax.Base.range_singleton", + "lemma_Pulse.Typing.Env.push_binding_bs", "lemma_Pulse.Typing.FV.freevars_close_term", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_Equality", "primitive_Prims.op_Negation", "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Some_v", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Syntax.Base.Mkst_term_term", "proj_equation_Pulse.Typing.Mkpost_hint_t_post", @@ -84,9 +94,12 @@ "projection_inverse_FStar.Tactics.Result.Success_v", "projection_inverse_Prims.Mkdtuple2__1", "projection_inverse_Prims.Mkdtuple2__2", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "projection_inverse_Pulse.Syntax.Base.Mkppname_name", "projection_inverse_Pulse.Syntax.Base.Tm_Return__0", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", @@ -94,24 +107,28 @@ "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", "refinement_interpretation_Tm_refine_cf9758cc2789ce185158d55a949d224a", "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "string_typing", "token_correspondence_Pulse.Syntax.Naming.freevars.fuel_instrumented", + "typing_FStar.Pervasives.Native.fst", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.complement", "typing_FStar.Set.mem", "typing_FStar.Set.singleton", "typing_Pulse.Checker.Pure.push_context", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.ppname_default", + "typing_Pulse.Syntax.Base.v_as_nv", "typing_Pulse.Syntax.Naming.close_term", - "typing_Pulse.Syntax.Naming.close_term_", "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Syntax.Naming.open_term", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.fresh", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.push_binding", "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__post" ], 0, - "76957e98301a16e6d2c5d79459d435fe" + "3d095a962e76a8f92d0ed18f0b6f56c5" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Return.fsti b/lib/steel/pulse/Pulse.Checker.Return.fsti index f1ec99385..e19c74107 100644 --- a/lib/steel/pulse/Pulse.Checker.Return.fsti +++ b/lib/steel/pulse/Pulse.Checker.Return.fsti @@ -11,5 +11,6 @@ val check (ctxt:term) (ctxt_typing:tot_typing g ctxt tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (st:st_term { Tm_Return? st.term }) : T.Tac (checker_result_t g ctxt post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Return.fsti.hints b/lib/steel/pulse/Pulse.Checker.Return.fsti.hints index 2608a36d4..578a2ce69 100644 --- a/lib/steel/pulse/Pulse.Checker.Return.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Return.fsti.hints @@ -1 +1 @@ -[ "\u00027㰈׸:L", [] ] \ No newline at end of file +[ ")I(8L*2", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Rewrite.fst b/lib/steel/pulse/Pulse.Checker.Rewrite.fst index f313150c7..f16d5f0d7 100644 --- a/lib/steel/pulse/Pulse.Checker.Rewrite.fst +++ b/lib/steel/pulse/Pulse.Checker.Rewrite.fst @@ -14,6 +14,7 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_Rewrite? t.term}) : T.Tac (checker_result_t g pre post_hint) = @@ -40,4 +41,4 @@ let check | Some token -> VE_Ext g p q token in let d = T_Rewrite _ p q p_typing equiv_p_q in - repack (try_frame_pre pre_typing d) post_hint t.range + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint t.range diff --git a/lib/steel/pulse/Pulse.Checker.Rewrite.fst.hints b/lib/steel/pulse/Pulse.Checker.Rewrite.fst.hints index dae6f211b..676fa5348 100644 --- a/lib/steel/pulse/Pulse.Checker.Rewrite.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.Rewrite.fst.hints @@ -1,5 +1,5 @@ [ - "\u000f\u001eS`\u001b*{\u0006]:", + "-&W\u0001$M#", [ [ "Pulse.Checker.Rewrite.check", @@ -48,7 +48,7 @@ "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.elab_env" ], 0, - "b55a96526231b0af5239ca57b13a46d4" + "59361209e8a80e7e337f1c8649a863a9" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.Rewrite.fsti b/lib/steel/pulse/Pulse.Checker.Rewrite.fsti index 283c92a07..e95abf43f 100644 --- a/lib/steel/pulse/Pulse.Checker.Rewrite.fsti +++ b/lib/steel/pulse/Pulse.Checker.Rewrite.fsti @@ -11,5 +11,6 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_Rewrite? t.term }) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.Rewrite.fsti.hints b/lib/steel/pulse/Pulse.Checker.Rewrite.fsti.hints index 3e4e1ddda..99cf83997 100644 --- a/lib/steel/pulse/Pulse.Checker.Rewrite.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.Rewrite.fsti.hints @@ -1 +1 @@ -[ ":]zVr\u0015@BE", [] ] \ No newline at end of file +[ "\u0014=(+URm}", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.STApp.fst b/lib/steel/pulse/Pulse.Checker.STApp.fst index a64ac6f1f..8c8f9ec98 100644 --- a/lib/steel/pulse/Pulse.Checker.STApp.fst +++ b/lib/steel/pulse/Pulse.Checker.STApp.fst @@ -56,7 +56,12 @@ let rec intro_uvars_for_logical_implicits (g:env) (uvs:env { disjoint uvs g }) ( | C_Tot ty -> intro_uvars_for_logical_implicits g uvs' (tm_pureapp t (Some Implicit) (null_var x)) ty end - | _ -> fail g None "intro_uvars_for_logical_implicits in stapp, unexpected type" + | _ -> + fail g None + (Printf.sprintf "check_stapp.intro_uvars_for_logical_implicits: expected an arrow type,\ + with an implicit parameter, found: %s" + (P.term_to_string ty)) + let instantaite_implicits (g:env) (t:st_term { Tm_STApp? t.term }) : T.Tac (uvs : env & @@ -76,7 +81,10 @@ let instantaite_implicits (g:env) (t:st_term { Tm_STApp? t.term }) | Some (head, q, arg) -> let uvs = mk_env (fstar_env g) in (| uvs, push_env g uvs, {term=Tm_STApp {head;arg_qual=q;arg}; range=t.range} |) - | _ -> fail g None "instantiate_implicits in stapp, unexpected term" + | _ -> + fail g (Some t.range) + (Printf.sprintf "check_stapp.instantiate_implicits: expected an application term, found: %s" + (P.term_to_string t)) #push-options "--z3rlimit_factor 4 --fuel 1 --ifuel 1" let check @@ -84,6 +92,7 @@ let check (ctxt:vprop) (ctxt_typing:tot_typing g0 ctxt tm_vprop) (post_hint:post_hint_opt g0) + (res_ppname:ppname) (t:st_term { Tm_STApp? t.term }) : T.Tac (checker_result_t g0 ctxt post_hint) = @@ -120,11 +129,11 @@ let check let d : st_typing _ _ (open_comp_with comp_typ arg) = T_STApp g head formal qual comp_typ arg (E dhead) (E darg) in let d = canonicalize_st_typing d in - let t = wr (Tm_STApp {head; arg_qual=qual; arg}) in + let t = { term = Tm_STApp {head; arg_qual=qual; arg}; range } in let c = (canon_comp (open_comp_with comp_typ arg)) in let d : st_typing g t c = d in - Prover.repack (Prover.try_frame_pre_uvs ctxt_typing uvs d) post_hint t.range + Prover.prove_post_hint (Prover.try_frame_pre_uvs ctxt_typing uvs d res_ppname) post_hint t.range | _ -> fail g (Some t.range) "Expected an effectful application; got a pure term (could it be partially applied by mistake?)" else fail g (Some t.range) (Printf.sprintf "Unexpected qualifier in head type %s of stateful application: head = %s, arg = %s" diff --git a/lib/steel/pulse/Pulse.Checker.STApp.fst.hints b/lib/steel/pulse/Pulse.Checker.STApp.fst.hints index 785d73b72..45f3b86ce 100644 --- a/lib/steel/pulse/Pulse.Checker.STApp.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.STApp.fst.hints @@ -1,5 +1,5 @@ [ - "\u001b\u0001qyc4l", + "\nz\u0006/}g", [ [ "Pulse.Checker.STApp.canon_comp", @@ -23,7 +23,7 @@ "typing_Pulse.Readback.readback_comp" ], 0, - "05f019acc0209bed8ef8e5d7d862f324" + "4f0ead0077f34ea40e1178b237bbd8e7" ], [ "Pulse.Checker.STApp.canonicalize_st_typing", @@ -85,7 +85,8 @@ 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_Pulse.Syntax.Base.Tm_STApp", "data_elim_Pulse.Syntax.Base.Mkbinder", @@ -103,6 +104,7 @@ "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.extends_with", + "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.binder", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.term", @@ -122,8 +124,6 @@ "proj_equation_Pulse.Syntax.Base.Mkbinder_binder_ty", "proj_equation_Pulse.Syntax.Base.Mkst_term_term", "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Some_a", - "projection_inverse_FStar.Pervasives.Native.Some_v", "projection_inverse_Pulse.Syntax.Base.Mkst_term_term", "projection_inverse_Pulse.Syntax.Base.Tm_STApp__0", "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", @@ -133,16 +133,16 @@ "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_de1d02ad66483edc481b70db20a6b9af", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.empty", "typing_FStar.Set.intersect", - "typing_FStar.Set.mem", + "string_typing", "typing_FStar.Map.contains", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ty", "typing_Pulse.Syntax.Base.ppname_default", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env" ], 0, - "fd47f212310ef870d7faa06198159316" + "006f12e7db00ecd299ea28364768085a" ], [ "Pulse.Checker.STApp.instantaite_implicits", @@ -151,6 +151,7 @@ 1, [ "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Syntax.Base_pretyping_0b425ab385a56835d52cd71c18622a32", "bool_inversion", "constructor_distinct_Pulse.Syntax.Base.Tm_STApp", "disc_equation_FStar.Pervasives.Native.Some", @@ -172,13 +173,14 @@ "projection_inverse_Pulse.Syntax.Base.Tm_STApp__0", "refinement_interpretation_Tm_refine_216a0d577fe6866b7566aea51095c305", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "string_typing", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "23bb0671ea4f4e399d45e842ba768ac7" + "5d31e5031960f32d5017e4282b4aa376" ], [ "Pulse.Checker.STApp.check", @@ -202,22 +204,25 @@ "equality_tok_Pulse.Syntax.Base.Implicit@tok", "equation_FStar.Reflection.Typing.pp_name_t", "equation_Prims.eqtype", "equation_Pulse.Checker.Pure.push_context", + "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Naming.open_comp_", "equation_Pulse.Syntax.Naming.open_comp_with", "equation_Pulse.Syntax.Naming.subst_comp", "equation_Pulse.Syntax.Pure.tm_arrow", "equation_Pulse.Typing.Env.extends_with", - "equation_Pulse.Typing.as_binder", + "equation_Pulse.Typing.as_binder", "equation_Pulse.Typing.wr", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.string", "kinding_Pulse.Syntax.Base.qualifier@tok", "lemma_FStar.Sealed.Inhabited.sealed_singleton", + "lemma_Pulse.Syntax.Base.range_singleton", "primitive_Prims.op_Equality", "proj_equation_Pulse.Syntax.Base.Mkbinder_binder_ppname", "proj_equation_Pulse.Syntax.Base.Mkbinder_binder_ty", "proj_equation_Pulse.Syntax.Base.Mkppname_name", + "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "projection_inverse_BoxBool_proj_0", "projection_inverse_FStar.Pervasives.Native.Mktuple3__1", "projection_inverse_FStar.Pervasives.Native.Mktuple3__2", @@ -229,6 +234,7 @@ "refinement_interpretation_Tm_refine_216a0d577fe6866b7566aea51095c305", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_c6ef4092b649a72c5716798791f93ffe", "string_typing", "typing_Pulse.Checker.Pure.push_context", "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", @@ -237,7 +243,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "eb8fcb1d5e633693170a9c7a74847f82" + "6981db68fd969ba669a690614e514da2" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.STApp.fsti b/lib/steel/pulse/Pulse.Checker.STApp.fsti index 61f6b6bd7..362ae0208 100644 --- a/lib/steel/pulse/Pulse.Checker.STApp.fsti +++ b/lib/steel/pulse/Pulse.Checker.STApp.fsti @@ -11,5 +11,6 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_STApp? t.term}) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.STApp.fsti.hints b/lib/steel/pulse/Pulse.Checker.STApp.fsti.hints index 388a12c24..ae33eda48 100644 --- a/lib/steel/pulse/Pulse.Checker.STApp.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.STApp.fsti.hints @@ -1 +1 @@ -[ "\"D,xj#\u000ex-", [] ] \ No newline at end of file +[ "}m@\tNp=j", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.VPropEquiv.fst.hints b/lib/steel/pulse/Pulse.Checker.VPropEquiv.fst.hints index be0d3dc33..c6c8a584e 100644 --- a/lib/steel/pulse/Pulse.Checker.VPropEquiv.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.VPropEquiv.fst.hints @@ -28,7 +28,7 @@ "subterm_ordering_Prims.Cons", "typing_FStar.List.Tot.Base.op_At" ], 0, - "4538ce6beba5b4751ea2da625733057e" + "f9c79950704654959da80ae1944ee8c3" ], [ "Pulse.Checker.VPropEquiv.list_as_vprop_assoc", diff --git a/lib/steel/pulse/Pulse.Checker.While.fst b/lib/steel/pulse/Pulse.Checker.While.fst index e8f2baf59..d2663f679 100644 --- a/lib/steel/pulse/Pulse.Checker.While.fst +++ b/lib/steel/pulse/Pulse.Checker.While.fst @@ -26,6 +26,7 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_While? t.term}) (check:check_t) : T.Tac (checker_result_t g pre post_hint) = @@ -38,13 +39,17 @@ let check in if not (Tm_ExistsSL? ex_inv.t) - then fail g None "Typechecked invariant is not an exists"; + then fail g (Some t.range) + (Printf.sprintf "check_while: typechecked invariant %s is not an existential" + (P.term_to_string ex_inv)); let Tm_ExistsSL u {binder_ppname=nm; binder_ty=ty} inv = ex_inv.t in if not (eq_tm ty tm_bool) || not (eq_univ u u0) - then fail g (Some nm.range) "While loop invariant exists but its witness type is not bool"; + then fail g (Some nm.range) + (Printf.sprintf "While loop invariant exists but its witness type is %s, expected bool" + (P.term_to_string ty)); let while_cond_comp_typing = while_cond_comp_typing u nm ty inv inv_typing in let (| res_typing, cond_pre_typing, x, post_typing |) = @@ -55,13 +60,15 @@ let check in let (| cond, cond_comp, cond_typing |) = + let ppname = mk_ppname_no_range "_while_c" in let r = check - (push_context "while condition" cond.range g) + (push_context "check_while_condition" cond.range g) (comp_pre (comp_while_cond nm inv)) cond_pre_typing (Some while_cond_hint) + ppname cond in - apply_checker_result_k r + apply_checker_result_k r ppname in if eq_comp cond_comp (comp_while_cond nm inv) then begin @@ -73,17 +80,19 @@ let check post_hint_from_comp_typing while_body_comp_typing in let (| body, body_comp, body_typing |) = + let ppname = mk_ppname_no_range "_while_b" in let r = check - (push_context "while body" body.range g) + (push_context "check_while_body" body.range g) (comp_pre (comp_while_body nm inv)) body_pre_typing (Some while_post_hint) + ppname body in - apply_checker_result_k r in + apply_checker_result_k r ppname in if eq_comp body_comp (comp_while_body nm inv) then let d = T_While g inv cond body inv_typing cond_typing body_typing in - repack (try_frame_pre pre_typing d) post_hint t.range + prove_post_hint (try_frame_pre pre_typing d res_ppname) post_hint t.range else fail g None (Printf.sprintf "Could not prove the inferred type of the while body matches the annotation\n\ Inferred type = %s\n\ diff --git a/lib/steel/pulse/Pulse.Checker.While.fst.hints b/lib/steel/pulse/Pulse.Checker.While.fst.hints index 67193399a..017fdc0a5 100644 --- a/lib/steel/pulse/Pulse.Checker.While.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.While.fst.hints @@ -1,5 +1,5 @@ [ - "&^Յ\u0018\u0017c", + "\u0018=Dyl\npmh0^", [ [ "Pulse.Checker.While.while_cond_comp_typing", @@ -15,7 +15,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "b14d3d22bf72bd0d10fa5c4d291b8b0d" + "072f488c0db5684ac184e8d832e11113" ], [ "Pulse.Checker.While.while_body_comp_typing", @@ -31,7 +31,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "13f42030ab770e44259f505620040ac4" + "dc1713e44937fea0c7a898366031c11c" ], [ "Pulse.Checker.While.check", @@ -41,9 +41,10 @@ [ "@MaxIFuel_assumption", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "Pulse.Syntax.Base_pretyping_b015b044c5bf00a3dd3df9fa711c87dd", "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", "Pulse.Typing_pretyping_85b09ae4ef91823fbf549acd09fde244", - "bool_inversion", "bool_typing", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", @@ -71,6 +72,7 @@ "equation_Pulse.Reflection.Util.bool_lid", "equation_Pulse.Syntax.Base.as_fv", "equation_Pulse.Syntax.Base.comp_pre", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.ppname_default", "equation_Pulse.Syntax.Base.range", "equation_Pulse.Syntax.Base.st_comp_of_comp", @@ -92,12 +94,12 @@ "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Pervasives.dtuple4", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "fuel_guarded_inversion_Pulse.Syntax.Base.term", "function_token_typing_Prims.__cache_version_number__", "function_token_typing_Prims.string", "int_inversion", - "interpretation_Tm_abs_3746c1a8012f4dd95a11504fc8eeab7d", "interpretation_Tm_abs_9cb689b25d040926e19a35940a7437be", "interpretation_Tm_abs_c8631188b49e797b2c9232f71b480642", "kinding_Pulse.Syntax.Base.term@tok", @@ -113,7 +115,6 @@ "proj_equation_Pulse.Syntax.Base.Mkterm_range", "proj_equation_Pulse.Syntax.Base.Mkterm_t", "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Mkdtuple4__3", "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", "projection_inverse_FStar.Pervasives.Native.None_a", @@ -136,13 +137,14 @@ "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_26851533b13187a52e8644f48af2401b", - "refinement_interpretation_Tm_refine_3065e1398390de4f00230edb22e635ab", + "refinement_interpretation_Tm_refine_32c58ace7239451bf6df460e56a19191", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "refinement_interpretation_Tm_refine_b7282a180f3a0f7af055d7b3110c2a7b", "refinement_interpretation_Tm_refine_c0259d9584cff5be1dbb133bed7b14f4", + "refinement_interpretation_Tm_refine_c36766333c13faf2a6d6de6db1e91a13", "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", "refinement_interpretation_Tm_refine_ce35950777565f210e37ac97fff16964", "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", @@ -161,13 +163,13 @@ "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.lookup", "typing_Pulse.Typing.Env.push_context", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion", + "typing_Pulse.Typing.Metatheory.Base.st_comp_typing_inversion", "typing_Pulse.Typing.comp_while_body", "typing_Pulse.Typing.comp_while_cond", "typing_Pulse.Typing.tm_bool", "unit_inversion" ], 0, - "5424213900051b0a80fefb2a4f357985" + "4e075784d193aa8c72c7dd3a4d67bdf4" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.While.fsti b/lib/steel/pulse/Pulse.Checker.While.fsti index 0e860b19e..1d300f3a4 100644 --- a/lib/steel/pulse/Pulse.Checker.While.fsti +++ b/lib/steel/pulse/Pulse.Checker.While.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term{Tm_While? t.term}) (check:check_t) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.While.fsti.hints b/lib/steel/pulse/Pulse.Checker.While.fsti.hints index 91f55dc91..14a644a06 100644 --- a/lib/steel/pulse/Pulse.Checker.While.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.While.fsti.hints @@ -1 +1 @@ -[ "8\u000b&l\u007f\u0004", [] ] \ No newline at end of file +[ "M;kOy\u000e?\t\u0002\u0003", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.WithLocal.fst b/lib/steel/pulse/Pulse.Checker.WithLocal.fst index 0047ecc4e..464406f30 100644 --- a/lib/steel/pulse/Pulse.Checker.WithLocal.fst +++ b/lib/steel/pulse/Pulse.Checker.WithLocal.fst @@ -6,6 +6,7 @@ open Pulse.Checker.Pure open Pulse.Checker.Base module T = FStar.Tactics.V2 +module P = Pulse.Syntax.Printer let extend_post_hint_for_local (g:env) (p:post_hint_for_env g) (init_t:term) (x:var { ~ (Set.mem x (dom g)) }) @@ -26,6 +27,7 @@ let check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_WithLocal? t.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) = @@ -54,17 +56,21 @@ let check | None -> fail g None "Allocating a mutable local variable expects an annotated post-condition" in if x `Set.mem` freevars post.post - then fail g None "Unexpected name clash in with_local" + then fail g None "Impossible! check_withlocal: unexpected name clash in with_local,\ + please file a bug-report" else let body_post = extend_post_hint_for_local g post init_t x in let (| opened_body, c_body, body_typing |) = - let r = check g_extended body_pre body_pre_typing (Some body_post) (open_st_term_nv body px) in - apply_checker_result_k r in + let r = + check g_extended body_pre body_pre_typing (Some body_post) binder.binder_ppname (open_st_term_nv body px) in + apply_checker_result_k r binder.binder_ppname in // // Checking post equality here to match the typing rule // if not (C_ST? c_body) - then fail g (Some body.range) "withlocal: body is not stt or postcondition mismatch" + then fail g (Some body.range) + (Printf.sprintf "check_withlocal: body computation type %s is not ST" + (P.comp_to_string c_body)) else let body = close_st_term opened_body x in assume (open_st_term (close_st_term opened_body x) x == opened_body); @@ -78,6 +84,9 @@ let check init_t_typing c_typing body_typing in - checker_result_for_st_typing (| _, _, d |) + checker_result_for_st_typing (| _, _, d |) res_ppname - else fail g None "Allocating a local variable: init type is not universe zero" + else fail g (Some t.range) + (Printf.sprintf "check_withlocal: allocating a local variable: type %s is not universe zero (computed %s)" + (P.term_to_string init) + (P.univ_to_string init_u)) diff --git a/lib/steel/pulse/Pulse.Checker.WithLocal.fst.hints b/lib/steel/pulse/Pulse.Checker.WithLocal.fst.hints index 2bf9a3b7d..5817e903c 100644 --- a/lib/steel/pulse/Pulse.Checker.WithLocal.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.WithLocal.fst.hints @@ -1,5 +1,5 @@ [ - "%y\u0011roXo", + "\u0016\u001f|Z\\Z!ۗS:_", [ [ "Pulse.Checker.WithLocal.extend_post_hint_for_local", @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "2135ae12dd24d7a408ea76ab0376f415" + "a3e75bab11ed7a39d651a2c3f74459ea" ], [ "Pulse.Checker.WithLocal.with_local_pre_typing", @@ -41,7 +41,7 @@ "@fuel_correspondence_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", "Pulse.Syntax.Base_pretyping_fe09dc1e796799f4bac0760e63f30d40", - "bool_inversion", "bool_typing", + "bool_inversion", "constructor_distinct_FStar.Pervasives.Native.None", "constructor_distinct_FStar.Pervasives.Native.Some", "constructor_distinct_FStar.Tactics.Result.Failed", @@ -68,6 +68,7 @@ "equation_Pulse.Syntax.Base.comp_post", "equation_Pulse.Syntax.Base.comp_pre", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.comp_u", "equation_Pulse.Syntax.Base.index", "equation_Pulse.Syntax.Base.ppname_default", @@ -81,8 +82,6 @@ "equation_Pulse.Syntax.Pure.term_of_nvar", "equation_Pulse.Syntax.Pure.tm_type", "equation_Pulse.Syntax.Pure.u0", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.env_extends", - "equation_Pulse.Typing.Env.extends_with", "equation_Pulse.Typing.Env.lookup", "equation_Pulse.Typing.FV.set_minus", "equation_Pulse.Typing.comp_post_matches_hint", @@ -94,6 +93,7 @@ "equation_Pulse.Typing.post_hint_opt", "fuel_guarded_inversion_FStar.Tactics.Result.__result", "fuel_guarded_inversion_Pulse.Syntax.Base.binder", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", "fuel_guarded_inversion_Pulse.Syntax.Base.st_comp", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", @@ -106,14 +106,12 @@ "int_typing", "kinding_Pulse.Syntax.Base.term@tok", "kinding_Pulse.Typing.post_hint_t@tok", "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Pervasives.invertOption", "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.mem_complement", "lemma_FStar.Set.mem_intersect", "lemma_FStar.Set.mem_singleton", "lemma_Pulse.Syntax.Base.range_singleton", "lemma_Pulse.Typing.Env.push_binding_bs", - "lemma_Pulse.Typing.Env.push_env_as_map", "lemma_Pulse.Typing.FV.freevars_close_st_term", "lemma_Pulse.Typing.post_hint_for_env_extends", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", @@ -158,10 +156,11 @@ "projection_inverse_Pulse.Typing.Mkpost_hint_t_u", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_460ca66dc5107a4a4bd5bf4443e1a214", "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", + "refinement_interpretation_Tm_refine_4a35837bb22dd5d80593cba92d284990", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", "refinement_interpretation_Tm_refine_a8346b95ba5a8f04395122ae3c6a0150", @@ -171,9 +170,8 @@ "refinement_interpretation_Tm_refine_f0ac051651fa0e095f1b2c1241fd6a3f", "string_typing", "token_correspondence_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.complement", "typing_FStar.Set.mem", - "typing_FStar.Set.singleton", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.complement", + "typing_FStar.Set.mem", "typing_FStar.Set.singleton", "typing_Pulse.Checker.Pure.push_context", "typing_Pulse.Checker.WithLocal.extend_post_hint_for_local", "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ppname", @@ -181,19 +179,16 @@ "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", "typing_Pulse.Syntax.Base.eq_univ", "typing_Pulse.Syntax.Base.ppname_default", - "typing_Pulse.Syntax.Base.uu___is_C_ST", "typing_Pulse.Syntax.Naming.close_st_term", "typing_Pulse.Syntax.Naming.freevars_st", "typing_Pulse.Syntax.Pure.u0", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fresh", "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.push_binding", - "typing_Pulse.Typing.Env.push_context", - "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g", - "typing_Pulse.Typing.mk_ref" + "typing_Pulse.Typing.Env.push_context", "typing_Pulse.Typing.mk_ref" ], 0, - "ba5ec091faca982df50e648bbe26d8b2" + "aba63061f6645ace26b942fe67526805" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.WithLocal.fsti b/lib/steel/pulse/Pulse.Checker.WithLocal.fsti index c58f4209f..836bb97ff 100644 --- a/lib/steel/pulse/Pulse.Checker.WithLocal.fsti +++ b/lib/steel/pulse/Pulse.Checker.WithLocal.fsti @@ -11,6 +11,7 @@ val check (pre:term) (pre_typing:tot_typing g pre tm_vprop) (post_hint:post_hint_opt g) + (res_ppname:ppname) (t:st_term { Tm_WithLocal? t.term }) (check:check_t) : T.Tac (checker_result_t g pre post_hint) diff --git a/lib/steel/pulse/Pulse.Checker.WithLocal.fsti.hints b/lib/steel/pulse/Pulse.Checker.WithLocal.fsti.hints index 063ca8589..0e5c99ec9 100644 --- a/lib/steel/pulse/Pulse.Checker.WithLocal.fsti.hints +++ b/lib/steel/pulse/Pulse.Checker.WithLocal.fsti.hints @@ -1 +1 @@ -[ "]L2P]^", [] ] \ No newline at end of file +[ "r\u001dP0Ne\u007f\\Mp", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Checker.fst b/lib/steel/pulse/Pulse.Checker.fst index 910303881..d64d9bfc9 100644 --- a/lib/steel/pulse/Pulse.Checker.fst +++ b/lib/steel/pulse/Pulse.Checker.fst @@ -135,6 +135,7 @@ let rec check (pre0:term) (pre0_typing: tot_typing g0 pre0 tm_vprop) (post_hint:post_hint_opt g0) + (res_ppname:ppname) (t:st_term) : T.Tac (checker_result_t g0 pre0 post_hint) = // T.print (Printf.sprintf "At %s: allow_inst: %s, context: %s, term: %s\n" @@ -150,40 +151,40 @@ let rec check let g = push_context (P.tag_of_st_term t) t.range g in match t.term with | Tm_Return _ -> - Return.check g pre pre_typing post_hint t + Return.check g pre pre_typing post_hint res_ppname t | Tm_Abs _ -> T.fail "Tm_Abs check should not have been called in the checker" | Tm_STApp _ -> - STApp.check g pre pre_typing post_hint t + STApp.check g pre pre_typing post_hint res_ppname t | Tm_ElimExists _ -> - Exists.check_elim_exists g pre pre_typing post_hint t + Exists.check_elim_exists g pre pre_typing post_hint res_ppname t | Tm_IntroExists { p; witnesses } -> (match instantiate_unknown_witnesses g t with | Some t -> - check g pre pre_typing post_hint t + check g pre pre_typing post_hint res_ppname t | None -> match witnesses with | [] -> fail g (Some t.range) "intro exists with empty witnesses" | [_] -> - Exists.check_intro_exists g pre pre_typing post_hint (maybe_intro_exists_erased t) None + Exists.check_intro_exists g pre pre_typing post_hint res_ppname (maybe_intro_exists_erased t) None | _ -> let t = transform_to_unary_intro_exists g p witnesses in - check g pre pre_typing post_hint t) + check g pre pre_typing post_hint res_ppname t) | Tm_Bind _ -> - Bind.check_bind g pre pre_typing post_hint t check + Bind.check_bind g pre pre_typing post_hint res_ppname t check | Tm_TotBind _ -> - Bind.check_tot_bind g pre pre_typing post_hint t check + Bind.check_tot_bind g pre pre_typing post_hint res_ppname t check | Tm_If { b; then_=e1; else_=e2; post=post_if } -> let post = match post_if, post_hint with | None, Some p -> p | Some p, None -> - Checker.Base.intro_post_hint g None None p + Checker.Base.intro_post_hint g None None p | Some p, Some q -> Pulse.Typing.Env.fail g (Some t.range) (Printf.sprintf @@ -199,11 +200,11 @@ let rec check Either annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional") in let (| x, t, pre', g1, k |) : checker_result_t g pre (Some post) = - If.check g pre pre_typing post b e1 e2 check in + If.check g pre pre_typing post res_ppname b e1 e2 check in (| x, t, pre', g1, k |) | Tm_While _ -> - While.check g pre pre_typing post_hint t check + While.check g pre pre_typing post_hint res_ppname t check | Tm_Match {sc;returns_=post_match;brs} -> // TODO : dedup @@ -226,29 +227,30 @@ let rec check "Pulse cannot yet infer a postcondition for a non-tail conditional statement;\n\ Either annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional") in - let (| x, ty, pre', g1, k |) = Match.check g pre pre_typing post sc brs check in + let (| x, ty, pre', g1, k |) = + Match.check g pre pre_typing post res_ppname sc brs check in (| x, ty, pre', g1, k |) | Tm_ProofHintWithBinders _ -> - Pulse.Checker.AssertWithBinders.check g pre pre_typing post_hint t check + Pulse.Checker.AssertWithBinders.check g pre pre_typing post_hint res_ppname t check | Tm_WithLocal _ -> - WithLocal.check g pre pre_typing post_hint t check + WithLocal.check g pre pre_typing post_hint res_ppname t check | Tm_Par _ -> - Par.check g pre pre_typing post_hint t check + Par.check g pre pre_typing post_hint res_ppname t check | Tm_IntroPure _ -> - Pulse.Checker.IntroPure.check g pre pre_typing post_hint t + Pulse.Checker.IntroPure.check g pre pre_typing post_hint res_ppname t | Tm_Admit _ -> - Admit.check g pre pre_typing post_hint t + Admit.check g pre pre_typing post_hint res_ppname t | Tm_Rewrite _ -> - Rewrite.check g pre pre_typing post_hint t + Rewrite.check g pre pre_typing post_hint res_ppname t | _ -> T.fail "Checker form not implemented" in - let (| x, t, pre', g1, k |) = r in - (| x, t, pre', g1, k_elab_trans k_elim_pure k |) + let (| x, g1, t, pre', k |) = r in + (| x, g1, t, pre', k_elab_trans k_elim_pure k |) diff --git a/lib/steel/pulse/Pulse.Checker.fst.hints b/lib/steel/pulse/Pulse.Checker.fst.hints index 9a58ee4ac..f92a4a77c 100644 --- a/lib/steel/pulse/Pulse.Checker.fst.hints +++ b/lib/steel/pulse/Pulse.Checker.fst.hints @@ -1,5 +1,5 @@ [ - "!I\u0019YX\u001f", + "S\u0014D\u001b\u001e \u0017eD", [ [ "Pulse.Checker.gen_names_for_unknowns", @@ -20,7 +20,7 @@ "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2" ], 0, - "f85ae6d017deb29697ece8aee5fd985b" + "3d77b4e736eded51d39024ec25ace24b" ], [ "Pulse.Checker.instantiate_unknown_witnesses", @@ -120,10 +120,11 @@ "disc_equation_Prims.Nil", "disc_equation_Pulse.Syntax.Base.Tm_IntroExists", "disc_equation_Pulse.Syntax.Base.Tm_Return", - "equation_FStar.Range.range", + "equation_FStar.Pervasives.dfst", "equation_FStar.Range.range", "equation_FStar.Reflection.Typing.fstar_top_env", "equation_Prims.nat", "equation_Pulse.Checker.Base.checker_res_matches_post_hint", + "equation_Pulse.Checker.Base.checker_result_inv", "equation_Pulse.Checker.Base.checker_result_t", "equation_Pulse.Checker.Exists.intro_exists_witness_singleton", "equation_Pulse.Checker.Pure.push_context", @@ -138,6 +139,7 @@ "fuel_guarded_inversion_FStar.Pervasives.Native.option", "fuel_guarded_inversion_FStar.Pervasives.dtuple5", "fuel_guarded_inversion_FStar.Tactics.Result.__result", + "fuel_guarded_inversion_Prims.dtuple2", "fuel_guarded_inversion_Prims.list", "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", "function_token_typing_Prims.__cache_version_number__", @@ -150,7 +152,7 @@ "proj_equation_FStar.Pervasives.Native.Mktuple2__1", "proj_equation_FStar.Pervasives.Native.Mktuple2__2", "proj_equation_FStar.Pervasives.Native.Some_v", - "proj_equation_Prims.Cons_tl", + "proj_equation_Prims.Cons_tl", "proj_equation_Prims.Mkdtuple2__1", "proj_equation_Pulse.Syntax.Base.Mkst_term_range", "proj_equation_Pulse.Syntax.Base.Mkst_term_term", "proj_equation_Pulse.Typing.Mkpost_hint_t_g", @@ -160,6 +162,7 @@ "projection_inverse_FStar.Pervasives.Mkdtuple5__3", "projection_inverse_FStar.Pervasives.Mkdtuple5__4", "projection_inverse_FStar.Pervasives.Mkdtuple5__5", + "projection_inverse_FStar.Pervasives.Mkdtuple5_b", "projection_inverse_FStar.Pervasives.Mkdtuple5_c", "projection_inverse_FStar.Pervasives.Mkdtuple5_d", "projection_inverse_FStar.Pervasives.Mkdtuple5_e", @@ -176,16 +179,15 @@ "projection_inverse_Pulse.Syntax.Base.Mkst_term___Tm_IntroExists__payload_witnesses", "projection_inverse_Pulse.Syntax.Base.Mkst_term_term", "projection_inverse_Pulse.Syntax.Base.Tm_IntroExists__0", - "refinement_interpretation_Tm_refine_0e7cec6ed8f6e8567fd60faa69f1ee6b", "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_4267d4c6afa07f3ba4570d839b7b0991", - "refinement_interpretation_Tm_refine_6d8ee78207eb8c69f5e44f08014b2ba6", + "refinement_interpretation_Tm_refine_562bee4b22524a77a83f0b80bb888777", "refinement_interpretation_Tm_refine_6e8e5238aadfc712ef5fa6bc6310c384", "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", "refinement_interpretation_Tm_refine_7f3ad0958305f2921bfac06f466396ae", "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_a8b89c35fa28900a81d627ef3d7cb576", + "refinement_interpretation_Tm_refine_b0ea3495ff282f69439c9d1354d6b870", "refinement_interpretation_Tm_refine_ba488b4f12660f6fd23fa65ec4b4a4ff", - "refinement_interpretation_Tm_refine_be0cb453a33d53da6ab9f91ceafd841d", "refinement_interpretation_Tm_refine_eed994d15518279ab75d745192d0d368", "string_typing", "typing_Pulse.Checker.Pure.push_context", "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__range", @@ -195,7 +197,7 @@ "typing_Pulse.Typing.__proj__Mkpost_hint_t__item__g" ], 0, - "730fe3f1d7819e3a1b0d6a09cb6b776f" + "8c19aedf6d12b33ca29d24bfd5a578fb" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Elaborate.Core.fst.hints b/lib/steel/pulse/Pulse.Elaborate.Core.fst.hints index 809a2eaca..f7f921ac0 100644 --- a/lib/steel/pulse/Pulse.Elaborate.Core.fst.hints +++ b/lib/steel/pulse/Pulse.Elaborate.Core.fst.hints @@ -20,7 +20,7 @@ "typing_Pulse.Syntax.Base.uu___is_C_STAtomic" ], 0, - "35386203512fdd2f572f27fd0f49e971" + "ce7c567d7cf45651c342eccdc3d166b0" ], [ "Pulse.Elaborate.Core.elab_sub", diff --git a/lib/steel/pulse/Pulse.Elaborate.Pure.fst.hints b/lib/steel/pulse/Pulse.Elaborate.Pure.fst.hints index b1304876f..9b0141c40 100644 --- a/lib/steel/pulse/Pulse.Elaborate.Pure.fst.hints +++ b/lib/steel/pulse/Pulse.Elaborate.Pure.fst.hints @@ -8,7 +8,7 @@ 1, [ "@query", "lemma_FStar.Pervasives.invertOption" ], 0, - "5b951ad65f0bbdec757407a9b2ccaa16" + "1581d9d3adc7c3fecfb5c9bd707c5379" ], [ "Pulse.Elaborate.Pure.elab_qual", diff --git a/lib/steel/pulse/Pulse.Elaborate.fst.hints b/lib/steel/pulse/Pulse.Elaborate.fst.hints index 7fad63adc..5c1032009 100644 --- a/lib/steel/pulse/Pulse.Elaborate.fst.hints +++ b/lib/steel/pulse/Pulse.Elaborate.fst.hints @@ -246,7 +246,7 @@ "typing_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok" ], 0, - "8c03e484bfc875ec022c9444d0c1c766" + "d0726d30dad34a7b6cd04407900619b9" ], [ "Pulse.Elaborate.elab_comp_open_commute'", @@ -1606,7 +1606,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "0f242001a5c801d32db3da079078e000" + "de0fe79f5e59bac391e3de21199df6c0" ], [ "Pulse.Elaborate.elab_freevars", diff --git a/lib/steel/pulse/Pulse.Elaborate.fsti.hints b/lib/steel/pulse/Pulse.Elaborate.fsti.hints index 1839be95d..1836d9a2f 100644 --- a/lib/steel/pulse/Pulse.Elaborate.fsti.hints +++ b/lib/steel/pulse/Pulse.Elaborate.fsti.hints @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "cc8a1b3a6b017bcdd6f91a37e1b30fe7" + "1d761983742bdb6ac9b614dc6805b8b9" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Main.fst.hints b/lib/steel/pulse/Pulse.Main.fst.hints index 817caf008..7d4505ce5 100644 --- a/lib/steel/pulse/Pulse.Main.fst.hints +++ b/lib/steel/pulse/Pulse.Main.fst.hints @@ -66,7 +66,7 @@ "typing_Tm_abs_9de830881eb0b7299cb605b2cfe97562" ], 0, - "a24c89fdd5330078016c9eb735b24da0" + "df8aef011d87b1c2b284752726b22bcd" ], [ "Pulse.Main.main", diff --git a/lib/steel/pulse/Pulse.Readback.fst.hints b/lib/steel/pulse/Pulse.Readback.fst.hints index 8eee6b9b3..76fd411ca 100644 --- a/lib/steel/pulse/Pulse.Readback.fst.hints +++ b/lib/steel/pulse/Pulse.Readback.fst.hints @@ -8,7 +8,7 @@ 1, [ "@query", "lemma_FStar.Pervasives.invertOption" ], 0, - "df18278bbecb2ec4f36a1b696ee6a3e0" + "ef583b91748e480c1f721592a02ade9a" ], [ "Pulse.Readback.try_readback_st_comp", diff --git a/lib/steel/pulse/Pulse.Soundness.Admit.fst.hints b/lib/steel/pulse/Pulse.Soundness.Admit.fst.hints index 14a30f91d..457911e72 100644 --- a/lib/steel/pulse/Pulse.Soundness.Admit.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Admit.fst.hints @@ -69,7 +69,7 @@ "typing_Pulse.Syntax.Base.tm_emp_inames" ], 0, - "157c60369dc0ee93390e7914d201dc0a" + "3dcef4d962880fc439cde719c9893fd6" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.Bind.fst.hints b/lib/steel/pulse/Pulse.Soundness.Bind.fst.hints index 5a751a397..e61443a51 100644 --- a/lib/steel/pulse/Pulse.Soundness.Bind.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Bind.fst.hints @@ -74,7 +74,7 @@ "typing_tok_FStar.Reflection.V2.Data.Q_Implicit@tok" ], 0, - "8f5ee8d52cf4375fd2a2b381a6d4d977" + "59366f7fe9bb57a20b171b280481f37a" ], [ "Pulse.Soundness.Bind.inst_bind_g", diff --git a/lib/steel/pulse/Pulse.Soundness.Bind.fsti.hints b/lib/steel/pulse/Pulse.Soundness.Bind.fsti.hints index 931ec2857..82a09e7de 100644 --- a/lib/steel/pulse/Pulse.Soundness.Bind.fsti.hints +++ b/lib/steel/pulse/Pulse.Soundness.Bind.fsti.hints @@ -25,7 +25,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "b4b1d8df157e7a6436428a0ff9f520d0" + "ad4a0b11486837a8f48715ffab0b67ac" ], [ "Pulse.Soundness.Bind.elab_bind_ghost_l_typing", diff --git a/lib/steel/pulse/Pulse.Soundness.Common.fst.hints b/lib/steel/pulse/Pulse.Soundness.Common.fst.hints index 3be8c0de1..dd4eae5de 100644 --- a/lib/steel/pulse/Pulse.Soundness.Common.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Common.fst.hints @@ -46,7 +46,7 @@ "typing_Tm_abs_9de830881eb0b7299cb605b2cfe97562" ], 0, - "4d5421012ce5c5f606f4bc4b1f0e9391" + "ecb909235eb655aaa923ee6a36a914e4" ], [ "Pulse.Soundness.Common.elab_term_opt", diff --git a/lib/steel/pulse/Pulse.Soundness.Comp.fst.hints b/lib/steel/pulse/Pulse.Soundness.Comp.fst.hints index 9cf2aeaad..2badc9083 100644 --- a/lib/steel/pulse/Pulse.Soundness.Comp.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Comp.fst.hints @@ -144,7 +144,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "2daa7e1e361b3761e1f6c418aac34464" + "5016ee55fb33db2b3a04a22b2e3774c1" ], [ "Pulse.Soundness.Comp.comp_typing_soundness", diff --git a/lib/steel/pulse/Pulse.Soundness.Exists.fst.hints b/lib/steel/pulse/Pulse.Soundness.Exists.fst.hints index e7ce3e625..a1fc1a5e5 100644 --- a/lib/steel/pulse/Pulse.Soundness.Exists.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Exists.fst.hints @@ -191,7 +191,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "3cdbaaf0203630ebce5ef9a31895ed55" + "9a83b41f1b77d01187ceeded4fef0049" ], [ "Pulse.Soundness.Exists.intro_exists_soundness", diff --git a/lib/steel/pulse/Pulse.Soundness.Frame.fst.hints b/lib/steel/pulse/Pulse.Soundness.Frame.fst.hints index e9b288c2b..9a2b83b07 100644 --- a/lib/steel/pulse/Pulse.Soundness.Frame.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Frame.fst.hints @@ -156,7 +156,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "3f6873d60f512fc916ee6cbb4154a93b" + "8ee89b340070db67a32320b37e9b5b1d" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.Lift.fst.hints b/lib/steel/pulse/Pulse.Soundness.Lift.fst.hints index fc01b0607..46397db24 100644 --- a/lib/steel/pulse/Pulse.Soundness.Lift.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Lift.fst.hints @@ -21,7 +21,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "623f50717110109f6b708a93b34a3937" + "fdbcdad2727f9019f9e314b303ac6fad" ], [ "Pulse.Soundness.Lift.elab_lift_stt_ghost_typing", diff --git a/lib/steel/pulse/Pulse.Soundness.Lift.fsti.hints b/lib/steel/pulse/Pulse.Soundness.Lift.fsti.hints index 8442f3ad6..6ff1c86e9 100644 --- a/lib/steel/pulse/Pulse.Soundness.Lift.fsti.hints +++ b/lib/steel/pulse/Pulse.Soundness.Lift.fsti.hints @@ -21,7 +21,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "22556b37eb53e4bc9a2b7951ca4e13d9" + "1e275de111e232d65264e7f87dad0009" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.Match.fst.hints b/lib/steel/pulse/Pulse.Soundness.Match.fst.hints index 672ffa1fb..7a4b33bd6 100644 --- a/lib/steel/pulse/Pulse.Soundness.Match.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Match.fst.hints @@ -15,7 +15,7 @@ "projection_inverse_Pulse.Typing.PC_Elab_sc_ty" ], 0, - "b22ddf498f2aed7022c36038e365924b" + "5d9938edd44dbcbc8708a5e4f0c6ebe0" ], [ "Pulse.Soundness.Match.match_soundness", diff --git a/lib/steel/pulse/Pulse.Soundness.Par.fst.hints b/lib/steel/pulse/Pulse.Soundness.Par.fst.hints index d31bb01b9..798de7342 100644 --- a/lib/steel/pulse/Pulse.Soundness.Par.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Par.fst.hints @@ -244,7 +244,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "9bbdbdc2eb0c71599ecb11f8a3f950a5" + "afa346ec3219d99fe07416ec1fe54f50" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.Return.fst.hints b/lib/steel/pulse/Pulse.Soundness.Return.fst.hints index 0bc302fe8..d2c52655b 100644 --- a/lib/steel/pulse/Pulse.Soundness.Return.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Return.fst.hints @@ -318,7 +318,7 @@ "typing_tok_Pulse.Syntax.Base.Implicit@tok" ], 0, - "953e81b68b0d9d84f263b6b25351cc65" + "cc975c1aca12d450b2fb48a5f7c09a08" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.Rewrite.fst.hints b/lib/steel/pulse/Pulse.Soundness.Rewrite.fst.hints index 7ed16112d..562231499 100644 --- a/lib/steel/pulse/Pulse.Soundness.Rewrite.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.Rewrite.fst.hints @@ -83,7 +83,7 @@ "typing_Pulse.Syntax.Base.tm_vprop", "typing_Pulse.Typing.tm_unit" ], 0, - "21f2b21ac2fe447b9e1afb1abfd02df1" + "3165f467a03e0b0ae8209d228f0aee6e" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.VPropEquiv.fst.hints b/lib/steel/pulse/Pulse.Soundness.VPropEquiv.fst.hints index 6ba1a9ac1..501f17e87 100644 --- a/lib/steel/pulse/Pulse.Soundness.VPropEquiv.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.VPropEquiv.fst.hints @@ -10,7 +10,7 @@ "@query", "equation_FStar.Sealed.Inhabited.is_sealed", "true_interp" ], 0, - "752ffd80c59d5173109627944c2d5bf7" + "93574e5dc6ae8b0c7177dc87f134a4b3" ], [ "Pulse.Soundness.VPropEquiv.inst_vprop_equiv_ext_aux", diff --git a/lib/steel/pulse/Pulse.Soundness.While.fst.hints b/lib/steel/pulse/Pulse.Soundness.While.fst.hints index 407ad1bed..466919f6e 100644 --- a/lib/steel/pulse/Pulse.Soundness.While.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.While.fst.hints @@ -152,7 +152,7 @@ "typing_tok_FStar.Reflection.V2.Data.Q_Explicit@tok" ], 0, - "82c18097ddd893de18b4c887b35a0bce" + "d8f664beb0427f4a4e72b53df1643b37" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Soundness.WithLocal.fst.hints b/lib/steel/pulse/Pulse.Soundness.WithLocal.fst.hints index 977ded6ab..14eaf59c6 100644 --- a/lib/steel/pulse/Pulse.Soundness.WithLocal.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.WithLocal.fst.hints @@ -27,7 +27,7 @@ "typing_Pulse.Typing.Env.as_map" ], 0, - "11551199969456d69e885ed4c313775e" + "342a9485605a674f888760af3e53cb96" ], [ "Pulse.Soundness.WithLocal.mk_t_abs", diff --git a/lib/steel/pulse/Pulse.Soundness.fst.hints b/lib/steel/pulse/Pulse.Soundness.fst.hints index 2411cd422..acc5dc220 100644 --- a/lib/steel/pulse/Pulse.Soundness.fst.hints +++ b/lib/steel/pulse/Pulse.Soundness.fst.hints @@ -27,7 +27,7 @@ "typing_Pulse.Typing.Env.dom" ], 0, - "b40810208bd28ddf2ea5e889bf01e464" + "cbab9db1467525a01bb1d5c4372c0785" ], [ "Pulse.Soundness.lift_soundness", diff --git a/lib/steel/pulse/Pulse.Syntax.Base.fst.hints b/lib/steel/pulse/Pulse.Syntax.Base.fst.hints index 3976bee92..0c062c945 100644 --- a/lib/steel/pulse/Pulse.Syntax.Base.fst.hints +++ b/lib/steel/pulse/Pulse.Syntax.Base.fst.hints @@ -34,6 +34,20 @@ 0, "df5a2b20da050c7609da1d4d62ebfc69" ], + [ + "Pulse.Syntax.Base.mk_ppname_no_range", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "equation_FStar.Sealed.Inhabited.is_sealed", + "equation_Pulse.Syntax.Base.range_singleton_trigger", "true_interp" + ], + 0, + "19ffa585ec760d9a6d27814e70afa8b3" + ], [ "Pulse.Syntax.Base.as_fv", 1, @@ -41,7 +55,7 @@ 1, [ "@query", "equation_Pulse.Syntax.Base.range_singleton_trigger" ], 0, - "d1c4223807106e7a1200ec6b1be1fa15" + "0da9822bf6aab8a0884553cde11e659c" ], [ "Pulse.Syntax.Base.tm_vprop", @@ -50,7 +64,7 @@ 1, [ "@query", "equation_Pulse.Syntax.Base.range_singleton_trigger" ], 0, - "b3765ef1b86efc8371ee80f6e5cd12c4" + "d1df4027608fc7a562ba7511e4d19b6d" ], [ "Pulse.Syntax.Base.tm_inames", @@ -125,7 +139,7 @@ "refinement_interpretation_Tm_refine_f30c5c1cb0a78245bc6b75b64fa49472" ], 0, - "e46c6f1afeb49c1aa4b9d0db496f59f7" + "c239a1322c662bf545bebca2253639a1" ], [ "Pulse.Syntax.Base.__proj__C_ST__item___0", @@ -197,7 +211,7 @@ "refinement_interpretation_Tm_refine_41d61c50c285817138d0c4ccdc37aecf" ], 0, - "e88f49a35f8f880a249d180cdca74883" + "5e70277846efe1a7196757eb6dc0b88d" ], [ "Pulse.Syntax.Base.__proj__Pat_Cons__item___1", @@ -264,7 +278,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "a2df455a6e0b9b50b4e093112319f128" + "34b71710b33d1ba3eb390b760ad885c3" ], [ "Pulse.Syntax.Base.proof_hint_type", @@ -280,7 +294,7 @@ "typing_FStar.Reflection.Types.name" ], 0, - "d2a12e1888205a25a1d805da221e0e06" + "2163d89a0dfb6dfb92a05986b48a1589" ], [ "Pulse.Syntax.Base.__proj__FOLD__item___0", @@ -292,7 +306,7 @@ "refinement_interpretation_Tm_refine_f02de02470d5e55219e650c427644816" ], 0, - "c1466da93054fb4488f312ddaeaffb92" + "fbc6c1b7efdaf6b956d0b527ebd4ee75" ], [ "Pulse.Syntax.Base.__proj__UNFOLD__item___0", @@ -313,7 +327,7 @@ 1, [ "@query" ], 0, - "d777a4916fde0f4ba7e2a6b3b5736e1f" + "e36f0b18bd9eba7cc0efa030b20363ac" ], [ "Pulse.Syntax.Base.eq_tm", diff --git a/lib/steel/pulse/Pulse.Syntax.Base.fsti b/lib/steel/pulse/Pulse.Syntax.Base.fsti index 1b0bc292e..8e76feec2 100644 --- a/lib/steel/pulse/Pulse.Syntax.Base.fsti +++ b/lib/steel/pulse/Pulse.Syntax.Base.fsti @@ -40,6 +40,11 @@ let mk_ppname (name:RT.pp_name_t) (range:FStar.Range.range) : ppname = { range = range } +let mk_ppname_no_range (s:string) : ppname = { + name = FStar.Sealed.seal s; + range = FStar.Range.range_0; +} + noeq type bv = { bv_index : index; diff --git a/lib/steel/pulse/Pulse.Syntax.Base.fsti.hints b/lib/steel/pulse/Pulse.Syntax.Base.fsti.hints index 4a75b9e98..a1a7373ef 100644 --- a/lib/steel/pulse/Pulse.Syntax.Base.fsti.hints +++ b/lib/steel/pulse/Pulse.Syntax.Base.fsti.hints @@ -1,5 +1,5 @@ [ - "\f\u001b)_a'\u00129", + "LF\u001eInS!bS", [ [ "Pulse.Syntax.Base.range_singleton", @@ -34,6 +34,20 @@ 0, "df5a2b20da050c7609da1d4d62ebfc69" ], + [ + "Pulse.Syntax.Base.mk_ppname_no_range", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "equation_FStar.Sealed.Inhabited.is_sealed", + "equation_Pulse.Syntax.Base.range_singleton_trigger", "true_interp" + ], + 0, + "19ffa585ec760d9a6d27814e70afa8b3" + ], [ "Pulse.Syntax.Base.as_fv", 1, @@ -41,7 +55,7 @@ 1, [ "@query", "equation_Pulse.Syntax.Base.range_singleton_trigger" ], 0, - "d1c4223807106e7a1200ec6b1be1fa15" + "0da9822bf6aab8a0884553cde11e659c" ], [ "Pulse.Syntax.Base.tm_vprop", @@ -50,7 +64,7 @@ 1, [ "@query", "equation_Pulse.Syntax.Base.range_singleton_trigger" ], 0, - "b3765ef1b86efc8371ee80f6e5cd12c4" + "d1df4027608fc7a562ba7511e4d19b6d" ], [ "Pulse.Syntax.Base.tm_inames", @@ -125,7 +139,7 @@ "refinement_interpretation_Tm_refine_f30c5c1cb0a78245bc6b75b64fa49472" ], 0, - "e46c6f1afeb49c1aa4b9d0db496f59f7" + "c239a1322c662bf545bebca2253639a1" ], [ "Pulse.Syntax.Base.__proj__C_ST__item___0", @@ -197,7 +211,7 @@ "refinement_interpretation_Tm_refine_41d61c50c285817138d0c4ccdc37aecf" ], 0, - "e88f49a35f8f880a249d180cdca74883" + "5e70277846efe1a7196757eb6dc0b88d" ], [ "Pulse.Syntax.Base.__proj__Pat_Cons__item___1", @@ -264,7 +278,7 @@ "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "a2df455a6e0b9b50b4e093112319f128" + "34b71710b33d1ba3eb390b760ad885c3" ], [ "Pulse.Syntax.Base.proof_hint_type", @@ -280,7 +294,7 @@ "typing_FStar.Reflection.Types.name" ], 0, - "d2a12e1888205a25a1d805da221e0e06" + "2163d89a0dfb6dfb92a05986b48a1589" ], [ "Pulse.Syntax.Base.__proj__FOLD__item___0", @@ -292,7 +306,7 @@ "refinement_interpretation_Tm_refine_f02de02470d5e55219e650c427644816" ], 0, - "c1466da93054fb4488f312ddaeaffb92" + "fbc6c1b7efdaf6b956d0b527ebd4ee75" ], [ "Pulse.Syntax.Base.__proj__UNFOLD__item___0", @@ -321,7 +335,7 @@ "projection_inverse_BoxBool_proj_0" ], 0, - "5ad7c7de05c6e5246f053c0173ca1ac2" + "5484fb9c27fb1903394a88c2ee5f2d4d" ], [ "Pulse.Syntax.Base.st_comp_of_comp", diff --git a/lib/steel/pulse/Pulse.Syntax.Naming.fst.hints b/lib/steel/pulse/Pulse.Syntax.Naming.fst.hints index 130deab35..8120772b7 100644 --- a/lib/steel/pulse/Pulse.Syntax.Naming.fst.hints +++ b/lib/steel/pulse/Pulse.Syntax.Naming.fst.hints @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "64447ce4aaaafb39036c7b59d1964ec7" + "e264670e418c000fec37d9fc34517584" ], [ "Pulse.Syntax.Naming.freevars", diff --git a/lib/steel/pulse/Pulse.Syntax.Naming.fsti.hints b/lib/steel/pulse/Pulse.Syntax.Naming.fsti.hints index d063fa33d..57b9a9cc6 100644 --- a/lib/steel/pulse/Pulse.Syntax.Naming.fsti.hints +++ b/lib/steel/pulse/Pulse.Syntax.Naming.fsti.hints @@ -14,7 +14,7 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "ed6a24ba41d8efe32480951a44c08e37" + "b1143a6bba15a8e3c833896e393eb1ff" ], [ "Pulse.Syntax.Naming.freevars", diff --git a/lib/steel/pulse/Pulse.Syntax.Printer.fst b/lib/steel/pulse/Pulse.Syntax.Printer.fst index 90c8d9086..e9c994063 100644 --- a/lib/steel/pulse/Pulse.Syntax.Printer.fst +++ b/lib/steel/pulse/Pulse.Syntax.Printer.fst @@ -82,6 +82,11 @@ let binder_to_string (b:binder) (T.unseal b.binder_ppname.name) (term_to_string b.binder_ty) +let ctag_to_string = function + | STT -> "ST" + | STT_Atomic -> "STAtomic" + | STT_Ghost -> "STGhost" + let comp_to_string (c:comp) : T.Tac string = match c with diff --git a/lib/steel/pulse/Pulse.Syntax.Printer.fst.hints b/lib/steel/pulse/Pulse.Syntax.Printer.fst.hints index 647e511ce..b2f2a4fb9 100644 --- a/lib/steel/pulse/Pulse.Syntax.Printer.fst.hints +++ b/lib/steel/pulse/Pulse.Syntax.Printer.fst.hints @@ -1,5 +1,5 @@ [ - "i֌Lӣ7S<", + "#X&;|", [ [ "Pulse.Syntax.Printer.universe_to_string", @@ -21,7 +21,7 @@ "typing_FStar.Reflection.V2.Builtins.inspect_universe" ], 0, - "991d302b48aa953c252fa41ad83bec5d" + "b3e8a17005de6ea1a903322553d56195" ], [ "Pulse.Syntax.Printer.univ_to_string", @@ -86,6 +86,22 @@ 0, "d31cbd3b9a8ba67870614a7275cab386" ], + [ + "Pulse.Syntax.Printer.ctag_to_string", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.STT", + "disc_equation_Pulse.Syntax.Base.STT_Atomic", + "disc_equation_Pulse.Syntax.Base.STT_Ghost", + "fuel_guarded_inversion_Pulse.Syntax.Base.ctag", + "projection_inverse_BoxBool_proj_0" + ], + 0, + "6b02eea266efcb18c1f9686c25282ee4" + ], [ "Pulse.Syntax.Printer.comp_to_string", 1, @@ -103,7 +119,7 @@ "projection_inverse_BoxBool_proj_0", "string_typing" ], 0, - "4e86e5572f49a3b4249a1c51cbfbb9eb" + "18d6125b244426a4c390f4caead02d00" ], [ "Pulse.Syntax.Printer.term_opt_to_string", @@ -168,7 +184,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__term" ], 0, - "4ca75bd887f159e448eb534ed5a2fa4f" + "ef932732105363abeba79862760f758e" ], [ "Pulse.Syntax.Printer.st_term_to_string'", @@ -237,7 +253,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__term" ], 0, - "283f63c2541e07cc88af14bb1692ce1b" + "30188921b5f3c08dc6e0483f51569678" ], [ "Pulse.Syntax.Printer.tag_of_comp", @@ -256,7 +272,7 @@ "projection_inverse_BoxBool_proj_0", "string_typing" ], 0, - "eb611b8acc7ce9175c13e5fc5bfba193" + "2ba54512348ce5944431965ee5c805e5" ], [ "Pulse.Syntax.Printer.print_st_head", @@ -349,7 +365,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkst_term__item__term" ], 0, - "864f4df6ddb371b65bad0e215043ead6" + "56ff58477a5d8a2994dfef84c0d82708" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Syntax.Printer.fsti b/lib/steel/pulse/Pulse.Syntax.Printer.fsti index 82e3a85d2..d5ec57d37 100644 --- a/lib/steel/pulse/Pulse.Syntax.Printer.fsti +++ b/lib/steel/pulse/Pulse.Syntax.Printer.fsti @@ -9,6 +9,7 @@ val univ_to_string (u:universe) : string val qual_to_string (q:option qualifier) : string val term_to_string (t:term) : T.Tac string val binder_to_string (b:binder) : T.Tac string +val ctag_to_string (c:ctag) : string val comp_to_string (c:comp) : T.Tac string val term_list_to_string (sep:string) (t:list term): T.Tac string val st_term_to_string (t:st_term) : T.Tac string diff --git a/lib/steel/pulse/Pulse.Syntax.Printer.fsti.hints b/lib/steel/pulse/Pulse.Syntax.Printer.fsti.hints index cabd1eddf..0a373540f 100644 --- a/lib/steel/pulse/Pulse.Syntax.Printer.fsti.hints +++ b/lib/steel/pulse/Pulse.Syntax.Printer.fsti.hints @@ -1 +1 @@ -[ "ZϮmȀ%u?\u0000\nc", [] ] \ No newline at end of file +[ "qd\u0006ٻ%\n/N\u0001", [] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Syntax.Pure.fst.hints b/lib/steel/pulse/Pulse.Syntax.Pure.fst.hints index c2520d463..00c933772 100644 --- a/lib/steel/pulse/Pulse.Syntax.Pure.fst.hints +++ b/lib/steel/pulse/Pulse.Syntax.Pure.fst.hints @@ -8,7 +8,7 @@ 1, [ "@query", "lemma_FStar.Pervasives.invertOption" ], 0, - "3b323a83a07659acc2f2c880f20f175c" + "1d2aff30ec30b3d7c0d9e3c1a9e70f5c" ], [ "Pulse.Syntax.Pure.tm_bvar", diff --git a/lib/steel/pulse/Pulse.Typing.Combinators.fst.hints b/lib/steel/pulse/Pulse.Typing.Combinators.fst.hints index 1a96babaa..f271b1f4a 100644 --- a/lib/steel/pulse/Pulse.Typing.Combinators.fst.hints +++ b/lib/steel/pulse/Pulse.Typing.Combinators.fst.hints @@ -31,7 +31,7 @@ "subterm_ordering_Pulse.Typing.VE_Trans" ], 0, - "e9eca75cdb4e48ce7620a8e942e1189f" + "859ea77a78966a2d869cc5154a4da92d" ], [ "Pulse.Typing.Combinators.mk_bind", @@ -406,10 +406,10 @@ "typing_Pulse.Syntax.Base.stateful_comp", "typing_Pulse.Syntax.Naming.freevars", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Metatheory.st_comp_typing_inversion" + "typing_Pulse.Typing.Metatheory.Base.st_comp_typing_inversion" ], 0, - "e662de8f78ca2b2a45ff0c40e42516c5" + "a03258934f96b7023f6e51010fe9e738" ], [ "Pulse.Typing.Combinators.st_typing_in_ctxt", @@ -417,15 +417,19 @@ 2, 1, [ - "@query", "disc_equation_Pulse.Syntax.Base.C_ST", + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.stateful_comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0" + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "c8c441c97729fd2009a746112a914d18" + "78ab3e65865f41ce01a26a7d98bcb368" ], [ "Pulse.Typing.Combinators.vprop_as_list", @@ -442,7 +446,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t" ], 0, - "73d387574dec4d8190390f1a9df89245" + "e5dd7a04680fae17436d8800ba00c44b" ], [ "Pulse.Typing.Combinators.list_as_vprop", diff --git a/lib/steel/pulse/Pulse.Typing.Combinators.fsti b/lib/steel/pulse/Pulse.Typing.Combinators.fsti index f5a55261f..fb0835d57 100644 --- a/lib/steel/pulse/Pulse.Typing.Combinators.fsti +++ b/lib/steel/pulse/Pulse.Typing.Combinators.fsti @@ -77,7 +77,7 @@ val apply_frame (#g:env) type st_typing_in_ctxt (g:env) (ctxt:vprop) (post_hint:post_hint_opt g) = t:st_term & - c:comp { stateful_comp c ==> (comp_pre c == ctxt /\ comp_post_matches_hint c post_hint) } & + c:comp_st { comp_pre c == ctxt /\ comp_post_matches_hint c post_hint } & st_typing g t c let rec vprop_as_list (vp:term) diff --git a/lib/steel/pulse/Pulse.Typing.Combinators.fsti.hints b/lib/steel/pulse/Pulse.Typing.Combinators.fsti.hints index 5859efcc1..128e26fdd 100644 --- a/lib/steel/pulse/Pulse.Typing.Combinators.fsti.hints +++ b/lib/steel/pulse/Pulse.Typing.Combinators.fsti.hints @@ -1,5 +1,5 @@ [ - "$~lkMth", + "ʱh\u001a\u000bm}\u0016\t\u001e\u000f(", [ [ "Pulse.Typing.Combinators.mk_bind", @@ -24,7 +24,7 @@ "refinement_interpretation_Tm_refine_c3db93a75dbfff93223215a880c044ae" ], 0, - "2a5da2441936a621c69f47f9e813e9ec" + "333378589454f4d53a828ec06d1f8bf3" ], [ "Pulse.Typing.Combinators.bind_res_and_post_typing", @@ -77,15 +77,19 @@ 2, 1, [ - "@query", "disc_equation_Pulse.Syntax.Base.C_ST", + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", "disc_equation_Pulse.Syntax.Base.C_STAtomic", "disc_equation_Pulse.Syntax.Base.C_STGhost", "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", "equation_Pulse.Syntax.Base.stateful_comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0" + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" ], 0, - "15befd2c80c705e53e605fac0c3472c0" + "01f5330de3aa1eba607b0f3375183198" ], [ "Pulse.Typing.Combinators.vprop_as_list", @@ -102,7 +106,7 @@ "typing_Pulse.Syntax.Base.__proj__Mkterm__item__t" ], 0, - "73d387574dec4d8190390f1a9df89245" + "e5dd7a04680fae17436d8800ba00c44b" ], [ "Pulse.Typing.Combinators.list_as_vprop", diff --git a/lib/steel/pulse/Pulse.Typing.Env.fst b/lib/steel/pulse/Pulse.Typing.Env.fst index d95890622..02753b85b 100644 --- a/lib/steel/pulse/Pulse.Typing.Env.fst +++ b/lib/steel/pulse/Pulse.Typing.Env.fst @@ -262,6 +262,17 @@ let extends_with_push (g1 g2 g3:env) assert (equal (push_binding g1 x n t) (push_env g2 (push_binding g3 x n t))) +#push-options "--admit_smt_queries true" +let rec subst_env (en:env) (ss:subst) + : en':env { fstar_env en == fstar_env en' /\ + dom en == dom en' } = + match bindings en with + | [] -> en + | _ -> + let x, t, en = remove_latest_binding en in + push_binding (subst_env en ss) x ppname_default (subst_term t ss) +#pop-options + let push_context g ctx r = { g with ctxt = Pulse.RuntimeUtils.extend_context ctx (Some r) g.ctxt } let push_context_no_range g ctx = { g with ctxt = Pulse.RuntimeUtils.extend_context ctx None g.ctxt } diff --git a/lib/steel/pulse/Pulse.Typing.Env.fst.hints b/lib/steel/pulse/Pulse.Typing.Env.fst.hints index 26619db59..04fcb43c4 100644 --- a/lib/steel/pulse/Pulse.Typing.Env.fst.hints +++ b/lib/steel/pulse/Pulse.Typing.Env.fst.hints @@ -1,5 +1,5 @@ [ - "\t\rzA\b9\u0013>", + "F + CT_ST g st (admit_st_comp_typing g st) + | C_STAtomic inames st -> + CT_STAtomic g inames st (admit()) (admit_st_comp_typing g st) + | C_STGhost inames st -> + CT_STGhost g inames st (admit()) (admit_st_comp_typing g st) + +let st_typing_correctness (#g:env) (#t:st_term) (#c:comp_st) + (_:st_typing g t c) + : comp_typing_u g c + = admit_comp_typing g c + +let add_frame_well_typed (#g:env) (#c:comp_st) (ct:comp_typing_u g c) + (#f:term) (ft:tot_typing g f tm_vprop) + : comp_typing_u g (add_frame c f) + = admit_comp_typing _ _ + +let comp_typing_inversion #g #c ct = + match ct with + | CT_ST _ _ st + | CT_STAtomic _ _ _ _ st + | CT_STGhost _ _ _ _ st -> st + +let st_comp_typing_inversion_cofinite (#g:env) (#st:_) (ct:st_comp_typing g st) = + admit(), admit(), (fun _ -> admit()) + +let st_comp_typing_inversion (#g:env) (#st:_) (ct:st_comp_typing g st) = + let STC g st x ty pre post = ct in + (| ty, pre, x, post |) + +let tm_exists_inversion (#g:env) (#u:universe) (#ty:term) (#p:term) + (_:tot_typing g (tm_exists_sl u (as_binder ty) p) tm_vprop) + (x:var { fresh_wrt x g (freevars p) } ) + : universe_of g ty u & + tot_typing (push_binding g x ppname_default ty) p tm_vprop + = admit(), admit() + +let pure_typing_inversion (#g:env) (#p:term) (_:tot_typing g (tm_pure p) tm_vprop) + : tot_typing g p (tm_fstar FStar.Reflection.Typing.tm_prop Range.range_0) + = admit () + +let tot_typing_weakening _ _ _ _ _ _ = admit () + +let non_informative_t_weakening (g g':env) (g1:env{ pairwise_disjoint g g1 g' }) + (u:universe) (t:term) + (d:non_informative_t (push_env g g') u t) + : non_informative_t (push_env (push_env g g1) g') u t = + let (| w, _ |) = d in + (| w, magic () |) + +let non_informative_c_weakening (g g':env) (g1:env{ pairwise_disjoint g g1 g' }) + (c:comp_st) + (d:non_informative_c (push_env g g') c) + : non_informative_c (push_env (push_env g g1) g') c = + non_informative_t_weakening g g' g1 _ _ d + +let bind_comp_weakening (g:env) (g':env { disjoint g g' }) + (#x:var) (#c1 #c2 #c3:comp) (d:bind_comp (push_env g g') x c1 c2 c3) + (g1:env { pairwise_disjoint g g1 g' }) + : Tot (bind_comp (push_env (push_env g g1) g') x c1 c2 c3) + (decreases d) = + + match d with + | Bind_comp _ x c1 c2 _ _ _ -> + assume (None? (lookup (push_env g g1) x)); + let y = fresh (push_env (push_env g g1) g') in + assume (~ (y `Set.mem` (freevars (comp_post c2)))); + Bind_comp _ x c1 c2 (magic ()) y (magic ()) + + | Bind_comp_ghost_l _ x c1 c2 n_d _ _ _ -> + assume (None? (lookup (push_env g g1) x)); + let y = fresh (push_env (push_env g g1) g') in + assume (~ (y `Set.mem` (freevars (comp_post c2)))); + Bind_comp_ghost_l _ x c1 c2 (non_informative_c_weakening g g' g1 _ n_d) (magic ()) y (magic ()) + + | Bind_comp_ghost_r _ x c1 c2 n_d _ _ _ -> + assume (None? (lookup (push_env g g1) x)); + let y = fresh (push_env (push_env g g1) g') in + assume (~ (y `Set.mem` (freevars (comp_post c2)))); + Bind_comp_ghost_r _ x c1 c2 (non_informative_c_weakening g g' g1 _ n_d) (magic ()) y (magic ()) + +let lift_comp_weakening (g:env) (g':env { disjoint g g'}) + (#c1 #c2:comp) (d:lift_comp (push_env g g') c1 c2) + (g1:env { pairwise_disjoint g g1 g' }) + : Tot (lift_comp (push_env (push_env g g1) g') c1 c2) + (decreases d) = + + match d with + | Lift_STAtomic_ST _ c -> Lift_STAtomic_ST _ c + | Lift_STGhost_STAtomic _ c non_informative_c -> + Lift_STGhost_STAtomic _ c (non_informative_c_weakening g g' g1 _ non_informative_c) + +let st_equiv_weakening (g:env) (g':env { disjoint g g' }) + (#c1 #c2:comp) (d:st_equiv (push_env g g') c1 c2) + (g1:env { pairwise_disjoint g g1 g' }) + : st_equiv (push_env (push_env g g1) g') c1 c2 = + match d with + | ST_VPropEquiv _ c1 c2 x _ _ _ _ _ -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + ST_VPropEquiv _ c1 c2 x (magic ()) (magic ()) (magic ()) (magic ()) (magic ()) + +let st_comp_typing_weakening (g:env) (g':env { disjoint g g' }) + (#s:st_comp) (d:st_comp_typing (push_env g g') s) + (g1:env { pairwise_disjoint g g1 g' }) + : st_comp_typing (push_env (push_env g g1) g') s = + match d with + | STC _ st x _ _ _ -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + STC _ st x (magic ()) (magic ()) (magic ()) + +let comp_typing_weakening (g:env) (g':env { disjoint g g' }) + (#c:comp) (#u:universe) (d:comp_typing (push_env g g') c u) + (g1:env { pairwise_disjoint g g1 g' }) + : comp_typing (push_env (push_env g g1) g') c u = + match d with + | CT_Tot _ t u _ -> CT_Tot _ t u (magic ()) + | CT_ST _ _ d -> CT_ST _ _ (st_comp_typing_weakening g g' d g1) + | CT_STAtomic _ inames _ _ d -> + CT_STAtomic _ inames _ (magic ()) (st_comp_typing_weakening g g' d g1) + | CT_STGhost _ inames _ _ d -> + CT_STGhost _ inames _ (magic ()) (st_comp_typing_weakening g g' d g1) + +// TODO: add precondition that g1 extends g' +let prop_validity_token_weakening (#g:env) (#t:term) + (token:prop_validity g t) + (g1:env) + : prop_validity g1 t = + admit (); + token + +#push-options "--z3rlimit_factor 4 --fuel 1 --ifuel 1" +let rec st_typing_weakening g g' t c d g1 + : Tot (st_typing (push_env (push_env g g1) g') t c) + (decreases d) = + + match d with + | T_Abs _ _ _ _ _ _ _ _ _ -> + // T_Abs is used only at the top, should not come up + magic () + + | T_STApp _ head ty q res arg _ _ -> + T_STApp _ head ty q res arg (magic ()) (magic ()) + + | T_Return _ c use_eq u t e post x_old _ _ _ -> + let x = fresh (push_env (push_env g g1) g') in + assume (~ (x `Set.mem` freevars post)); + // x is only used to open and then close + assume (comp_return c use_eq u t e post x_old == + comp_return c use_eq u t e post x); + T_Return _ c use_eq u t e post x (magic ()) (magic ()) (magic ()) + + | T_Lift _ e c1 c2 d_c1 d_lift -> + T_Lift _ e c1 c2 (st_typing_weakening g g' e c1 d_c1 g1) + (lift_comp_weakening g g' d_lift g1) + + | T_Bind _ e1 e2 c1 c2 b x c d_e1 _ d_e2 d_bc -> + let d_e1 : st_typing (push_env (push_env g g1) g') e1 c1 = + st_typing_weakening g g' e1 c1 d_e1 g1 in + // + // When we call it, g' will actually be empty + // And they way bind checker invokes the lemma, we also know x is not in g1 + // But we must fix it cleanly + // Perhaps typing rules should take a thunk, fun (x:var) ... + // + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + let d_e2 + : st_typing (push_binding (push_env g g') x ppname_default (comp_res c1)) + (open_st_term_nv e2 (b.binder_ppname, x)) + c2 = d_e2 in + assert (equal (push_binding (push_env g g') x ppname_default (comp_res c1)) + (push_env g (push_binding g' x ppname_default (comp_res c1)))); + let d_e2 + : st_typing (push_env g (push_binding g' x ppname_default (comp_res c1))) + (open_st_term_nv e2 (b.binder_ppname, x)) + c2 = d_e2 in + let d_e2 + : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default (comp_res c1))) + (open_st_term_nv e2 (b.binder_ppname, x)) + c2 = st_typing_weakening g (push_binding g' x ppname_default (comp_res c1)) _ _ d_e2 g1 in + assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default (comp_res c1))) + (push_binding (push_env (push_env g g1) g') x ppname_default (comp_res c1))); + let d_e2 + : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default (comp_res c1)) + (open_st_term_nv e2 (b.binder_ppname, x)) + c2 = d_e2 in + let d_bc = bind_comp_weakening g g' d_bc g1 in + T_Bind _ e1 e2 c1 c2 b x c d_e1 (magic ()) d_e2 d_bc + + | T_TotBind _ e1 e2 t1 c2 x _ d_e2 -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + let d_e2 + : st_typing (push_binding (push_env g g') x ppname_default t1) + (open_st_term_nv e2 (v_as_nv x)) + c2 = d_e2 in + assert (equal (push_binding (push_env g g') x ppname_default t1) + (push_env g (push_binding g' x ppname_default t1))); + let d_e2 + : st_typing (push_env g (push_binding g' x ppname_default t1)) + (open_st_term_nv e2 (v_as_nv x)) + c2 = d_e2 in + let d_e2 + : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default t1)) + (open_st_term_nv e2 (v_as_nv x)) + c2 = st_typing_weakening g (push_binding g' x ppname_default t1) _ _ d_e2 g1 in + assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default t1)) + (push_binding (push_env (push_env g g1) g') x ppname_default t1)); + let d_e2 + : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default t1) + (open_st_term_nv e2 (v_as_nv x)) + c2 = d_e2 in + + T_TotBind _ e1 e2 t1 c2 x (magic ()) d_e2 + + | T_If _ b e1 e2 c uc hyp _ d_e1 d_e2 _ -> + assume (~ (hyp `Set.mem` dom g')); + assume (~ (hyp `Set.mem` dom g1)); + let d_e1 + : st_typing (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) + e1 c = d_e1 in + assert (equal (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) + (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)))); + let d_e1 + : st_typing (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) + e1 c = d_e1 in + let d_e1 + : st_typing (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) + e1 c = st_typing_weakening g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) _ _ d_e1 g1 in + assert (equal (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) + (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))); + let d_e1 + : st_typing (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) + e1 c = d_e1 in + let d_e2 + : st_typing (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) + e2 c = d_e2 in + assert (equal (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) + (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)))); + let d_e2 + : st_typing (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) + e2 c = d_e2 in + let d_e2 + : st_typing (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) + e2 c = st_typing_weakening g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) _ _ d_e2 g1 in + assert (equal (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) + (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))); + let d_e2 + : st_typing (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) + e2 c = d_e2 in + + T_If _ b e1 e2 c uc hyp (magic ()) d_e1 d_e2 (magic ()) + + | T_Match _ sc_u sc_ty sc d_sc_ty d_sc c brs d_brs d_pats_complete -> magic () + + | T_Frame _ e c frame _ d_e -> + T_Frame _ e c frame (magic ()) (st_typing_weakening g g' e c d_e g1) + + | T_Equiv _ e c c' d_e d_eq -> + T_Equiv _ e c c' (st_typing_weakening g g' e c d_e g1) (st_equiv_weakening g g' d_eq g1) + + | T_IntroPure _ p _ token -> T_IntroPure _ p (magic ()) (prop_validity_token_weakening token _) + + | T_ElimExists _ u t p x _ _ -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + T_ElimExists _ u t p x (magic ()) (magic ()) + + | T_IntroExists _ u b p e _ _ _ -> + T_IntroExists _ u b p e (magic ()) (magic ()) (magic ()) + + | T_IntroExistsErased _ u b p e _ _ _ -> + T_IntroExistsErased _ u b p e (magic ()) (magic ()) (magic ()) + + | T_While _ inv cond body _ cond_typing body_typing -> + T_While _ inv cond body (magic ()) + (st_typing_weakening g g' cond (comp_while_cond ppname_default inv) cond_typing g1) + (st_typing_weakening g g' body (comp_while_body ppname_default inv) body_typing g1) + + | T_Par _ eL cL eR cR x cL_typing cR_typing eL_typing eR_typing -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + T_Par _ eL cL eR cR x + (comp_typing_weakening g g' cL_typing g1) + (comp_typing_weakening g g' cR_typing g1) + (st_typing_weakening g g' eL cL eL_typing g1) + (st_typing_weakening g g' eR cR eR_typing g1) + + | T_WithLocal _ init body init_t c x _ _ d_c d_body -> + assume (~ (x `Set.mem` dom g')); + assume (~ (x `Set.mem` dom g1)); + let d_body + : st_typing (push_binding (push_env g g') x ppname_default (mk_ref init_t)) + (open_st_term_nv body (v_as_nv x)) + (comp_withlocal_body x init_t init c) = d_body in + assert (equal (push_binding (push_env g g') x ppname_default (mk_ref init_t)) + (push_env g (push_binding g' x ppname_default (mk_ref init_t)))); + let d_body + : st_typing (push_env g (push_binding g' x ppname_default (mk_ref init_t))) + (open_st_term_nv body (v_as_nv x)) + (comp_withlocal_body x init_t init c) = d_body in + let d_body + : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default (mk_ref init_t))) + (open_st_term_nv body (v_as_nv x)) + (comp_withlocal_body x init_t init c) + = st_typing_weakening g (push_binding g' x ppname_default (mk_ref init_t)) _ _ d_body g1 in + assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default (mk_ref init_t))) + (push_binding (push_env (push_env g g1) g') x ppname_default (mk_ref init_t))); + let d_body + : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default (mk_ref init_t)) + (open_st_term_nv body (v_as_nv x)) + (comp_withlocal_body x init_t init c) = d_body in + T_WithLocal _ init body init_t c x (magic ()) (magic ()) + (comp_typing_weakening g g' d_c g1) + d_body + + | T_Rewrite _ p q _ _ -> T_Rewrite _ p q (magic ()) (magic ()) + + | T_Admit _ s c d_s -> T_Admit _ s c (st_comp_typing_weakening g g' d_s g1) +#pop-options + +#push-options "--admit_smt_queries true" +let non_informative_t_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (u:universe) (t1:term) + (d:non_informative_t (push_env g (push_env (singleton_env (fstar_env g) x t) g')) u t1) + + : non_informative_t (push_env g (subst_env g' (nt x e))) u (subst_term t1 (nt x e)) = + + let ss = nt x e in + + let (| w, _ |) = d in + (| subst_term w ss, magic () |) + +let non_informative_c_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (c:comp) + (d:non_informative_c (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c) + + : non_informative_c (push_env g (subst_env g' (nt x e))) (subst_comp c (nt x e)) = + + non_informative_t_subst g x t g' e_typing _ _ d + +let lift_comp_subst + (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#c1 #c2:comp) + (d:lift_comp (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c1 c2) + + : lift_comp (push_env g (subst_env g' (nt x e))) + (subst_comp c1 (nt x e)) + (subst_comp c2 (nt x e)) = + + let ss = nt x e in + + match d with + | Lift_STAtomic_ST _ c -> + Lift_STAtomic_ST _ (subst_comp c ss) + + | Lift_STGhost_STAtomic _ c d_non_informative -> + Lift_STGhost_STAtomic _ (subst_comp c ss) + (non_informative_c_subst g x t g' e_typing _ d_non_informative) + +let bind_comp_subst + (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#y:var) (#c1 #c2 #c3:comp) (d:bind_comp (push_env g (push_env (singleton_env (fstar_env g) x t) g')) y c1 c2 c3) + : bind_comp (push_env g (subst_env g' (nt x e))) + y + (subst_comp c1 (nt x e)) + (subst_comp c2 (nt x e)) + (subst_comp c3 (nt x e)) = + + let ss = nt x e in + + match d with + | Bind_comp _ y c1 c2 _ z _ -> + Bind_comp _ y (subst_comp c1 ss) + (subst_comp c2 ss) + (magic ()) + z + (magic ()) + + | Bind_comp_ghost_l _ y c1 c2 d_non_informative _ z _ -> + Bind_comp_ghost_l _ y (subst_comp c1 ss) + (subst_comp c2 ss) + (non_informative_c_subst g x t g' e_typing _ d_non_informative) + (magic ()) + z + (magic ()) + + | Bind_comp_ghost_r _ y c1 c2 d_non_informative _ z _ -> + Bind_comp_ghost_r _ y (subst_comp c1 ss) + (subst_comp c2 ss) + (non_informative_c_subst g x t g' e_typing _ d_non_informative) + (magic ()) + z + (magic ()) + +let st_equiv_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#c1 #c2:comp) (d:st_equiv (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c1 c2) + : st_equiv (push_env g (subst_env g' (nt x e))) + (subst_comp c1 (nt x e)) + (subst_comp c2 (nt x e)) = + match d with + | ST_VPropEquiv _ c1 c2 y _ _ _ _ _ -> + ST_VPropEquiv _ (subst_comp c1 (nt x e)) + (subst_comp c2 (nt x e)) + y + (magic ()) + (magic ()) + (magic ()) + (magic ()) + (magic ()) + +let st_comp_typing_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#s:st_comp) (d:st_comp_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) s) + : st_comp_typing (push_env g (subst_env g' (nt x e))) + (subst_st_comp s (nt x e)) = + match d with + | STC _ s y _ _ _ -> + STC _ (subst_st_comp s (nt x e)) + y + (magic ()) + (magic ()) + (magic ()) + +let comp_typing_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#c:comp) (#u:universe) (d:comp_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c u) + : comp_typing (push_env g (subst_env g' (nt x e))) + (subst_comp c (nt x e)) u = + match d with + | CT_Tot _ t u _ -> + CT_Tot _ (subst_term t (nt x e)) u (magic ()) + | CT_ST _ s d_s -> + CT_ST _ (subst_st_comp s (nt x e)) (st_comp_typing_subst g x t g' e_typing d_s) + | CT_STAtomic _ inames s _ d_s -> + CT_STAtomic _ inames (subst_st_comp s (nt x e)) (magic ()) (st_comp_typing_subst g x t g' e_typing d_s) + | CT_STGhost _ inames s _ d_s -> + CT_STGhost _ inames (subst_st_comp s (nt x e)) (magic ()) (st_comp_typing_subst g x t g' e_typing d_s) + + +let coerce_eq (#a #b:Type) (x:a) (_:squash (a == b)) : y:b { y == x } = x + +let rec st_typing_subst g x t g' #e e_typing #e1 #c1 e1_typing + : Tot (st_typing (push_env g (subst_env g' (nt x e))) + (subst_st_term e1 (nt x e)) + (subst_comp c1 (nt x e))) + (decreases e1_typing) = + + let ss = nt x e in + + match e1_typing with + | T_Abs _ _ _ _ _ _ _ _ _ -> magic () + + | T_STApp _ head ty q res arg _ _ -> + T_STApp _ (subst_term head ss) + (subst_term ty ss) + q + (subst_comp res ss) + (subst_term arg ss) + (magic ()) + (magic ()) + + | T_Return _ c use_eq u t e post x _ _ _ -> + T_Return _ c use_eq u + (subst_term t ss) + (subst_term e ss) + (subst_term post ss) + x + (magic ()) + (magic ()) + (magic ()) + + | T_Lift _ e c1 c2 d_e d_lift -> + T_Lift _ (subst_st_term e ss) + (subst_comp c1 ss) + (subst_comp c2 ss) + (st_typing_subst g x t g' e_typing d_e) + (lift_comp_subst g x t g' e_typing d_lift) + + | T_Bind _ e1 e2 c1 c2 b y c d_e1 _ d_e2 d_bc -> + T_Bind _ (subst_st_term e1 ss) + (subst_st_term e2 ss) + (subst_comp c1 ss) + (subst_comp c2 ss) + (subst_binder b ss) + y + (subst_comp c ss) + (st_typing_subst g x t g' e_typing d_e1) + (magic ()) + (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default (comp_res c1)) e_typing d_e2) ()) + (bind_comp_subst g x t g' e_typing d_bc) + + | T_TotBind _ e1 e2 t1 c2 y _ d_e2 -> + T_TotBind _ (subst_term e1 ss) + (subst_st_term e2 ss) + (subst_term t1 ss) + (subst_comp c2 ss) + y + (magic ()) + (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default t1) e_typing d_e2) ()) + + | T_If _ b e1 e2 c uc hyp _ d_e1 d_e2 _ -> + T_If _ (subst_term b ss) + (subst_st_term e1 ss) + (subst_st_term e2 ss) + (subst_comp c ss) + uc + hyp + (magic ()) + (coerce_eq (st_typing_subst g x t (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) e_typing d_e1) ()) + (coerce_eq (st_typing_subst g x t (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) e_typing d_e2) ()) + (magic ()) + + | T_Match _ _ _ _ _ _ _ _ _ _ -> magic () + + | T_Frame _ e c frame _ d_e -> + T_Frame _ (subst_st_term e ss) + (subst_comp c ss) + (subst_term frame ss) + (magic ()) + (st_typing_subst g x t g' e_typing d_e) + + | T_Equiv _ e c c' d_e d_eq -> + T_Equiv _ (subst_st_term e ss) + (subst_comp c ss) + (subst_comp c' ss) + (st_typing_subst g x t g' e_typing d_e) + (st_equiv_subst g x t g' e_typing d_eq) + + | T_IntroPure _ p _ _ -> + T_IntroPure _ (subst_term p ss) + (magic ()) + (magic ()) + + | T_ElimExists _ u t p y _ _ -> + T_ElimExists _ u (subst_term t ss) (subst_term p ss) y (magic ()) (magic ()) + + | T_IntroExists _ u b p e _ _ _ -> + T_IntroExists _ u (subst_binder b ss) + (subst_term p ss) + (subst_term e ss) + (magic ()) + (magic ()) + (magic ()) + + | T_IntroExistsErased _ u b p e _ _ _ -> + T_IntroExistsErased _ u (subst_binder b ss) + (subst_term p ss) + (subst_term e ss) + (magic ()) + (magic ()) + (magic ()) + + | T_While _ inv cond body _ cond_typing body_typing -> + T_While _ (subst_term inv ss) + (subst_st_term cond ss) + (subst_st_term body ss) + (magic ()) + (st_typing_subst g x t g' e_typing cond_typing) + (st_typing_subst g x t g' e_typing body_typing) + + | T_Par _ eL cL eR cR y d_cL d_cR d_eL d_eR -> + T_Par _ (subst_st_term eL ss) + (subst_comp cL ss) + (subst_st_term eR ss) + (subst_comp cR ss) + y + (comp_typing_subst g x t g' e_typing d_cL) + (comp_typing_subst g x t g' e_typing d_cR) + (st_typing_subst g x t g' e_typing d_eL) + (st_typing_subst g x t g' e_typing d_eR) + + | T_WithLocal _ init body init_t c y _ _ d_c d_body -> + T_WithLocal _ (subst_term init ss) + (subst_st_term body ss) + (subst_term init_t ss) + (subst_comp c ss) + y + (magic ()) + (magic ()) + (comp_typing_subst g x t g' e_typing d_c) + (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default (mk_ref init_t)) e_typing d_body) ()) + + | T_Rewrite _ p q _ _ -> + T_Rewrite _ (subst_term p ss) + (subst_term q ss) + (magic ()) + (magic ()) + + | T_Admit _ s c d_s -> + T_Admit _ (subst_st_comp s ss) c (st_comp_typing_subst g x t g' e_typing d_s) +#pop-options diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fst.hints b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fst.hints new file mode 100644 index 000000000..5c03a976c --- /dev/null +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fst.hints @@ -0,0 +1,1052 @@ +[ + "2(:]}{T13o", + [ + [ + "Pulse.Typing.Metatheory.Base.comp_typing_u", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "4f2a63f23be33da61c74b0d64f4700f8" + ], + [ + "Pulse.Typing.Metatheory.Base.admit_comp_typing", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "constructor_distinct_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.comp_u", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_Pulse.Syntax.Base.C_ST__0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "84de79f95fc3d91a6b619cb2ab9d2793" + ], + [ + "Pulse.Typing.Metatheory.Base.comp_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "6ed3bb04f09c4048310c051a9c9294d0" + ], + [ + "Pulse.Typing.Metatheory.Base.comp_typing_inversion", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "constructor_distinct_Pulse.Syntax.Base.C_ST", + "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", + "constructor_distinct_Pulse.Syntax.Base.C_STGhost", + "constructor_distinct_Pulse.Syntax.Base.C_Tot", + "data_elim_Pulse.Typing.CT_ST", "data_elim_Pulse.Typing.CT_STAtomic", + "data_elim_Pulse.Typing.CT_STGhost", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "disc_equation_Pulse.Typing.CT_ST", + "disc_equation_Pulse.Typing.CT_STAtomic", + "disc_equation_Pulse.Typing.CT_STGhost", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.comp_u", + "equation_Pulse.Syntax.Base.st_comp_of_comp", + "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Typing.Metatheory.Base.comp_typing_u", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Typing.comp_typing", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", + "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", + "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", + "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", + "projection_inverse_Pulse.Syntax.Base.C_ST__0", + "projection_inverse_Pulse.Syntax.Base.C_Tot__0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "7744685a17cdec687c045153a4a737aa" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion_cofinite", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "1eed16705e64ce3ba0d564a1c0a8aa6c" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion_cofinite", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "73b3b6ba3dd0b28a5875e50b335dfd02" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "33bc6338b32b456b902b466f2b13416b" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Typing.STC", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Naming.open_term", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_Pulse.Typing.STC_g", + "projection_inverse_Pulse.Typing.STC_st", + "projection_inverse_Pulse.Typing.STC_x", + "refinement_interpretation_Tm_refine_6067909eb7e26441b043722acc4cd3cf", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "bb8bfdd8ac017e8d29fb5d4130d6bb69" + ], + [ + "Pulse.Typing.Metatheory.Base.tm_exists_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "161766957172704111ce5db172730911" + ], + [ + "Pulse.Typing.Metatheory.Base.tm_exists_inversion", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", + "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", + "typing_Pulse.Typing.Env.as_map" + ], + 0, + "1d56383ce8115532894431c0c7459cb6" + ], + [ + "Pulse.Typing.Metatheory.Base.pure_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", + "data_elim_Pulse.Syntax.Base.Mkterm", + "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", + "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", + "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", + "equation_FStar.Reflection.Types.name", + "equation_FStar.Reflection.Typing.tm_prop", + "equation_Pulse.Syntax.Base.not_tv_unknown", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.tm_vprop", + "equation_Pulse.Syntax.Base.with_range", + "lemma_FStar.Reflection.Typing.inspect_pack", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "typing_FStar.Reflection.Const.prop_qn", + "typing_FStar.Reflection.V2.Builtins.pack_fv", + "typing_Pulse.Syntax.Base.tm_vprop" + ], + 0, + "c27abe8099ab0e19892a3ca7e119c441" + ], + [ + "Pulse.Typing.Metatheory.Base.pure_typing_inversion", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", + "data_elim_Pulse.Syntax.Base.Mkterm", + "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", + "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", + "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", + "equation_FStar.Reflection.Types.name", + "equation_FStar.Reflection.Typing.tm_prop", + "equation_Pulse.Syntax.Base.not_tv_unknown", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.tm_vprop", + "equation_Pulse.Syntax.Base.with_range", + "lemma_FStar.Reflection.Typing.inspect_pack", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "typing_FStar.Reflection.Const.prop_qn", + "typing_FStar.Reflection.V2.Builtins.pack_fv", + "typing_Pulse.Syntax.Base.tm_vprop" + ], + 0, + "3978fc73c096745ad025c48e564d6082" + ], + [ + "Pulse.Typing.Metatheory.Base.tot_typing_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "ddb58d64255bc87a9fc264d295319aec" + ], + [ + "Pulse.Typing.Metatheory.Base.tot_typing_weakening", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "45d35456d70fcdb4ea7d69d850fa1990" + ], + [ + "Pulse.Typing.Metatheory.Base.non_informative_t_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a" + ], + 0, + "001638d07f758adfadd47ef0e5388e49" + ], + [ + "Pulse.Typing.Metatheory.Base.non_informative_t_weakening", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "a77078c8c99d754c5949574c9e614407" + ], + [ + "Pulse.Typing.Metatheory.Base.non_informative_c_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a" + ], + 0, + "b872c80b43f2671cf7352038c6476c1c" + ], + [ + "Pulse.Typing.Metatheory.Base.non_informative_c_weakening", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "719f0ac8aec8018176e39deb4edad52a" + ], + [ + "Pulse.Typing.Metatheory.Base.bind_comp_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "Pulse.Syntax.Base_pretyping_b015b044c5bf00a3dd3df9fa711c87dd", + "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Typing.Bind_comp", + "data_elim_Pulse.Typing.Bind_comp_ghost_l", + "data_elim_Pulse.Typing.Bind_comp_ghost_r", + "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "disc_equation_Pulse.Typing.Bind_comp", + "disc_equation_Pulse.Typing.Bind_comp_ghost_l", + "disc_equation_Pulse.Typing.Bind_comp_ghost_r", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.bind_comp_ghost_l_compatible", + "equation_Pulse.Typing.bind_comp_ghost_l_pre", + "equation_Pulse.Typing.bind_comp_ghost_r_compatible", + "equation_Pulse.Typing.bind_comp_ghost_r_pre", "false_interp", + "fuel_guarded_inversion_FStar.Pervasives.Native.option", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Typing.bind_comp", + "function_token_typing_Prims.int", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", + "int_typing", "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Map.lemma_SelConcat1", + "lemma_FStar.Set.disjoint_not_in_both", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_2b6798c0823f5b5055723c1967d93598", + "refinement_interpretation_Tm_refine_2f458fa5f654138dcffb245813d49f42", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_4f650fc2932b3d31e01200d48fa18e08", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_611ba448e793150e81181c9e427cdb95", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", + "refinement_interpretation_Tm_refine_fecc77b374a5a63ebf9e46c0cac6c2d5", + "typing_FStar.Map.contains", "typing_FStar.Map.domain", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.lookup" + ], + 0, + "0d99dcdab8f87a13017e52341158244d" + ], + [ + "Pulse.Typing.Metatheory.Base.lift_comp_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Typing.Lift_STAtomic_ST", + "data_elim_Pulse.Typing.Lift_STGhost_STAtomic", + "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_Pulse.Typing.Lift_STAtomic_ST", + "disc_equation_Pulse.Typing.Lift_STGhost_STAtomic", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "fuel_guarded_inversion_Pulse.Typing.lift_comp", + "function_token_typing_Prims.__cache_version_number__", + "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env" + ], + 0, + "e3a30f8d6e6a6260f7720f37b481a428" + ], + [ + "Pulse.Typing.Metatheory.Base.st_equiv_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_Tm_unit", + "data_elim_Pulse.Typing.ST_VPropEquiv", + "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.st_equiv_pre", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", + "fuel_guarded_inversion_Pulse.Typing.st_equiv", + "function_token_typing_Prims.int", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_Pulse.Typing.ST_VPropEquiv_c1", + "projection_inverse_Pulse.Typing.ST_VPropEquiv_c2", + "projection_inverse_Pulse.Typing.ST_VPropEquiv_x", + "refinement_interpretation_Tm_refine_28c4a39499c4c8364ff6badb936a6446", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_5ecc2896a3c67fb3a0af5aa92f4f89a7", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.comp_res", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.push_env" + ], + 0, + "ea4839a7977efae5d9d34eef3269799b" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Typing.STC", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.vprop", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "fuel_guarded_inversion_FStar.Pervasives.Native.option", + "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", + "function_token_typing_Prims.int", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", + "int_typing", "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_Pulse.Typing.STC_st", + "projection_inverse_Pulse.Typing.STC_x", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_6067909eb7e26441b043722acc4cd3cf", + "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", + "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__post", + "typing_Pulse.Syntax.Naming.freevars", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.lookup", "typing_Pulse.Typing.Env.push_env" + ], + 0, + "0ccc2ab39fdd63d272c85371ebf363a4" + ], + [ + "Pulse.Typing.Metatheory.Base.comp_typing_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "data_elim_Pulse.Typing.CT_ST", "data_elim_Pulse.Typing.CT_STAtomic", + "data_elim_Pulse.Typing.CT_STGhost", "data_elim_Pulse.Typing.CT_Tot", + "disc_equation_Pulse.Typing.CT_ST", + "disc_equation_Pulse.Typing.CT_STAtomic", + "disc_equation_Pulse.Typing.CT_STGhost", + "disc_equation_Pulse.Typing.CT_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "fuel_guarded_inversion_Pulse.Typing.comp_typing", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "63d4c92493bb6d279a8761f7c077c435" + ], + [ + "Pulse.Typing.Metatheory.Base.st_typing_weakening", + 1, + 1, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "b63c7c9992e4ddeded7f7e01d4a8abe2" + ], + [ + "Pulse.Typing.Metatheory.Base.st_typing_weakening", + 2, + 1, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_5371726821249ae5627a70b6626e6c93", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "da59a6775894b8d67cf28510d65c7bfa" + ], + [ + "Pulse.Typing.Metatheory.Base.st_typing_weakening", + 3, + 1, + 1, + [ + "@MaxFuel_assumption", "@MaxIFuel_assumption", + "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", + "@fuel_correspondence_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", + "@fuel_irrelevance_FStar.List.Tot.Base.append.fuel_instrumented", + "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", + "binder_x_01e6cbbfeab3ba416b144f2c9223a2d4_2", + "binder_x_1ad99e5433effa849e32ef9adfa111a0_0", + "binder_x_253c3a680f4c9d78f6acd0325daa4c3c_1", + "binder_x_5b6164b63aa5506d6aacf8c001ca520e_5", + "binder_x_7112683412d09ec447176f925f3fb12f_4", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.None", + "constructor_distinct_FStar.Pervasives.Native.Some", + "constructor_distinct_Prims.Cons", + "data_elim_Pulse.Syntax.Base.Mkppname", + "data_elim_Pulse.Typing.ST_VPropEquiv", + "data_elim_Pulse.Typing.T_Admit", "data_elim_Pulse.Typing.T_Bind", + "data_elim_Pulse.Typing.T_ElimExists", + "data_elim_Pulse.Typing.T_Equiv", "data_elim_Pulse.Typing.T_Frame", + "data_elim_Pulse.Typing.T_If", + "data_elim_Pulse.Typing.T_IntroExists", + "data_elim_Pulse.Typing.T_IntroExistsErased", + "data_elim_Pulse.Typing.T_IntroPure", + "data_elim_Pulse.Typing.T_Lift", "data_elim_Pulse.Typing.T_Par", + "data_elim_Pulse.Typing.T_Return", + "data_elim_Pulse.Typing.T_Rewrite", "data_elim_Pulse.Typing.T_STApp", + "data_elim_Pulse.Typing.T_TotBind", "data_elim_Pulse.Typing.T_While", + "data_elim_Pulse.Typing.T_WithLocal", + "disc_equation_FStar.Pervasives.Native.None", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "disc_equation_Pulse.Typing.T_Abs", + "disc_equation_Pulse.Typing.T_Admit", + "disc_equation_Pulse.Typing.T_Bind", + "disc_equation_Pulse.Typing.T_ElimExists", + "disc_equation_Pulse.Typing.T_Equiv", + "disc_equation_Pulse.Typing.T_Frame", + "disc_equation_Pulse.Typing.T_If", + "disc_equation_Pulse.Typing.T_IntroExists", + "disc_equation_Pulse.Typing.T_IntroExistsErased", + "disc_equation_Pulse.Typing.T_IntroPure", + "disc_equation_Pulse.Typing.T_Lift", + "disc_equation_Pulse.Typing.T_Match", + "disc_equation_Pulse.Typing.T_Par", + "disc_equation_Pulse.Typing.T_Return", + "disc_equation_Pulse.Typing.T_Rewrite", + "disc_equation_Pulse.Typing.T_STApp", + "disc_equation_Pulse.Typing.T_TotBind", + "disc_equation_Pulse.Typing.T_While", + "disc_equation_Pulse.Typing.T_WithLocal", + "equation_FStar.List.Tot.Base.op_At", + "equation_FStar.Pervasives.Native.fst", + "equation_FStar.Pervasives.Native.snd", + "equation_FStar.Reflection.Typing.fstar_env", + "equation_FStar.Reflection.Typing.fstar_env_fvs", + "equation_FStar.Reflection.Typing.fstar_top_env", + "equation_FStar.Reflection.Typing.pp_name_t", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Sealed.Inhabited.sealed", + "equation_FStar.Sealed.Inhabited.sealed_", + "equation_FStar.Set.disjoint", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_res", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.nvar", + "equation_Pulse.Syntax.Base.ppname_default", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.stateful_comp", + "equation_Pulse.Syntax.Base.typ", + "equation_Pulse.Syntax.Base.v_as_nv", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.binding", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.env_bindings", + "equation_Pulse.Typing.Env.equal", + "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.mk_eq2", "equation_Pulse.Typing.mk_ref", + "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", + "equation_with_fuel_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", + "fuel_guarded_inversion_FStar.Pervasives.Native.option", + "fuel_guarded_inversion_Prims.list", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", + "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", + "fuel_guarded_inversion_Pulse.Typing.st_equiv", + "fuel_guarded_inversion_Pulse.Typing.st_typing", + "function_token_typing_FStar.Reflection.Types.term", + "function_token_typing_Prims.__cache_version_number__", + "function_token_typing_Prims.int", + "function_token_typing_Prims.string", + "function_token_typing_Pulse.Typing.Env.binding", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", + "kinding_Pulse.Syntax.Base.ppname@tok", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.List.Tot.Properties.append_l_nil", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Map.lemma_InDomUpd2", "lemma_FStar.Map.lemma_UpdDomain", + "lemma_FStar.Sealed.Inhabited.sealed_singleton", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", + "lemma_FStar.Set.lemma_equal_refl", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "lemma_FStar.Set.mem_singleton", + "lemma_FStar.Set.mem_union", + "lemma_Pulse.Syntax.Base.range_singleton", + "lemma_Pulse.Typing.Env.equal_elim", + "lemma_Pulse.Typing.Env.push_binding_as_map", + "lemma_Pulse.Typing.Env.push_binding_bs", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_bindings", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "primitive_Prims.op_Equality", + "proj_equation_FStar.Pervasives.Native.Mktuple2__1", + "proj_equation_FStar.Pervasives.Native.Mktuple2__2", + "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", + "proj_equation_Pulse.Syntax.Base.Mkppname_name", + "proj_equation_Pulse.Syntax.Base.Mkppname_range", + "projection_inverse_BoxBool_proj_0", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", + "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", + "projection_inverse_Prims.Cons_a", + "projection_inverse_Prims.Cons_hd", + "projection_inverse_Prims.Cons_tl", + "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", + "refinement_interpretation_Tm_refine_00889bd3bc6adb297f9f40795de5a761", + "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", + "refinement_interpretation_Tm_refine_1e3b46ef574b7c7b56e6f48d45a4bd20", + "refinement_interpretation_Tm_refine_2059be2dd67c6c852866b0f758545706", + "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", + "refinement_interpretation_Tm_refine_28c4a39499c4c8364ff6badb936a6446", + "refinement_interpretation_Tm_refine_2ee1d1f639c54669fffde14441581c40", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_55ade9f9fb5b5fd33c51185b667c6eed", + "refinement_interpretation_Tm_refine_65c667c598fddb3432338b957782b444", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "refinement_interpretation_Tm_refine_90df79b9523270fa979deaff360b5107", + "refinement_interpretation_Tm_refine_a8f9fbb656279b348f0b063081025b13", + "refinement_interpretation_Tm_refine_b62cb64ffa39b6d9d2eb56acf9f4cf34", + "refinement_interpretation_Tm_refine_b9943bf670d3eeece9d9f2e3e534ed66", + "refinement_interpretation_Tm_refine_c3a8a0db088f6874b298e9191f4d6f5c", + "refinement_interpretation_Tm_refine_c985e04063fe38cddadc0a297161b419", + "refinement_interpretation_Tm_refine_d79470205dca7f56c9b5a5da9d23b961", + "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", + "refinement_interpretation_Tm_refine_f327b3b66854e57c59289f8c259581e7", + "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "string_typing", "subterm_ordering_Pulse.Typing.T_Bind", + "subterm_ordering_Pulse.Typing.T_Equiv", + "subterm_ordering_Pulse.Typing.T_Frame", + "subterm_ordering_Pulse.Typing.T_If", + "subterm_ordering_Pulse.Typing.T_Lift", + "subterm_ordering_Pulse.Typing.T_Par", + "subterm_ordering_Pulse.Typing.T_TotBind", + "subterm_ordering_Pulse.Typing.T_While", + "subterm_ordering_Pulse.Typing.T_WithLocal", + "typing_FStar.Map.contains", "typing_FStar.Pervasives.Native.fst", + "typing_FStar.Pervasives.Native.snd", + "typing_FStar.Pervasives.Native.uu___is_None", + "typing_FStar.Reflection.Typing.bool_fv", + "typing_FStar.Reflection.Typing.lookup_fvar", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", + "typing_FStar.Set.empty", "typing_FStar.Set.intersect", + "typing_FStar.Set.mem", "typing_FStar.Set.singleton", + "typing_FStar.Set.union", + "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ppname", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", + "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", + "typing_Pulse.Syntax.Base.comp_res", + "typing_Pulse.Syntax.Base.ppname_default", + "typing_Pulse.Syntax.Base.uu___is_C_ST", + "typing_Pulse.Syntax.Base.v_as_nv", + "typing_Pulse.Syntax.Naming.freevars_st", + "typing_Pulse.Syntax.Pure.u0", "typing_Pulse.Typing.Env.as_map", + "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.lookup", + "typing_Pulse.Typing.Env.push_binding", + "typing_Pulse.Typing.Env.push_env", "typing_Pulse.Typing.mk_eq2", + "typing_Pulse.Typing.mk_ref", "typing_Pulse.Typing.tm_bool", + "typing_Pulse.Typing.tm_false", "typing_Pulse.Typing.tm_true" + ], + 0, + "5f6b10a4ebab5b3e5b2025584326c48a" + ], + [ + "Pulse.Typing.Metatheory.Base.veq_weakening", + 1, + 1, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "42fa03b072055a8ae381c40050b1d2cd" + ] + ] +] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti new file mode 100644 index 000000000..440ca4f1f --- /dev/null +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti @@ -0,0 +1,92 @@ +module Pulse.Typing.Metatheory.Base +open Pulse.Syntax +open Pulse.Syntax.Naming +open Pulse.Typing + +let comp_typing_u (g:env) (c:comp_st) = comp_typing g c (comp_u c) + +val admit_comp_typing (g:env) (c:comp_st) + : comp_typing_u g c + +val st_typing_correctness (#g:env) (#t:st_term) (#c:comp_st) + (_:st_typing g t c) + : comp_typing_u g c + +val comp_typing_inversion (#g:env) (#c:comp_st) (ct:comp_typing_u g c) + : st_comp_typing g (st_comp_of_comp c) + +val st_comp_typing_inversion_cofinite (#g:env) (#st:_) (ct:st_comp_typing g st) + : (universe_of g st.res st.u & + tot_typing g st.pre tm_vprop & + (x:var{fresh_wrt x g (freevars st.post)} -> //this part is tricky, to get the quantification on x + tot_typing (push_binding g x ppname_default st.res) (open_term st.post x) tm_vprop)) + +val st_comp_typing_inversion (#g:env) (#st:_) (ct:st_comp_typing g st) + : (universe_of g st.res st.u & + tot_typing g st.pre tm_vprop & + x:var{fresh_wrt x g (freevars st.post)} & + tot_typing (push_binding g x ppname_default st.res) (open_term st.post x) tm_vprop) + +val tm_exists_inversion (#g:env) (#u:universe) (#ty:term) (#p:term) + (_:tot_typing g (tm_exists_sl u (as_binder ty) p) tm_vprop) + (x:var { fresh_wrt x g (freevars p) } ) + : universe_of g ty u & + tot_typing (push_binding g x ppname_default ty) p tm_vprop + +val pure_typing_inversion (#g:env) (#p:term) (_:tot_typing g (tm_pure p) tm_vprop) + : tot_typing g p (tm_fstar FStar.Reflection.Typing.tm_prop Range.range_0) + +val tot_typing_weakening + (g:env) (g':env { disjoint g g' }) + (t:term) (ty:typ) (_:tot_typing (push_env g g') t ty) + (g1:env { pairwise_disjoint g g1 g' }) + : tot_typing (push_env (push_env g g1) g') t ty + +// let comp_st_with_post (c:comp_st) (post:term) : c':comp_st { st_comp_of_comp c' == ({ st_comp_of_comp c with post} <: st_comp) } = +// match c with +// | C_ST st -> C_ST { st with post } +// | C_STGhost i st -> C_STGhost i { st with post } +// | C_STAtomic i st -> C_STAtomic i {st with post} + +// let comp_st_with_pre (c:comp_st) (pre:term) : comp_st = +// match c with +// | C_ST st -> C_ST { st with pre } +// | C_STGhost i st -> C_STGhost i { st with pre } +// | C_STAtomic i st -> C_STAtomic i {st with pre } + +val st_typing_weakening + (g:env) (g':env { disjoint g g' }) + (t:st_term) (c:comp) (_:st_typing (push_env g g') t c) + (g1:env { pairwise_disjoint g g1 g' }) + : st_typing (push_env (push_env g g1) g') t c + +let veq_weakening + (g:env) (g':env { disjoint g g' }) + (#v1 #v2:vprop) (_:vprop_equiv (push_env g g') v1 v2) + (g1:env { pairwise_disjoint g g1 g' }) + : vprop_equiv (push_env (push_env g g1) g') v1 v2 = magic () + +let nt (x:var) (t:term) = [ NT x t ] + +val st_typing_subst + (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#e1:st_term) (#c1:comp_st) + (e1_typing:st_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) e1 c1) + + : st_typing (push_env g (subst_env g' (nt x e))) + (subst_st_term e1 (nt x e)) + (subst_comp c1 (nt x e)) + +let vprop_equiv_subst + (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) + (#e:term) + (e_typing:tot_typing g e t) + (#p1:term) (#p2:term) + (veq:vprop_equiv (push_env g (push_env (singleton_env (fstar_env g) x t) g')) p1 p2) + +: vprop_equiv (push_env g (subst_env g' (nt x e))) + (subst_term p1 (nt x e)) + (subst_term p2 (nt x e)) = + admit () diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti.hints b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti.hints new file mode 100644 index 000000000..47c4b3e9e --- /dev/null +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.Base.fsti.hints @@ -0,0 +1,337 @@ +[ + "\u0017U<\u0014@\u0010i7HiK", + [ + [ + "Pulse.Typing.Metatheory.Base.comp_typing_u", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "0a5522265d725f8db8698bebd00088e2" + ], + [ + "Pulse.Typing.Metatheory.Base.comp_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "disc_equation_Pulse.Syntax.Base.C_ST", + "disc_equation_Pulse.Syntax.Base.C_STAtomic", + "disc_equation_Pulse.Syntax.Base.C_STGhost", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.stateful_comp", + "fuel_guarded_inversion_Pulse.Syntax.Base.comp", + "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" + ], + 0, + "0703365ac22db0057b9409aa385842d9" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion_cofinite", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "00cecfdace16fb43b63d4fd4726fbe75" + ], + [ + "Pulse.Typing.Metatheory.Base.st_comp_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "b6ad6f7892ed29cbb7408d4b27afc40d" + ], + [ + "Pulse.Typing.Metatheory.Base.tm_exists_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", + "equation_Pulse.Typing.fresh_wrt", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "f670e43065dc1a30a3a3acbbb33af092" + ], + [ + "Pulse.Typing.Metatheory.Base.pure_typing_inversion", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", + "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", + "data_elim_Pulse.Syntax.Base.Mkterm", + "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", + "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", + "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", + "equation_FStar.Reflection.Types.name", + "equation_FStar.Reflection.Typing.tm_prop", + "equation_Pulse.Syntax.Base.not_tv_unknown", + "equation_Pulse.Syntax.Base.range", + "equation_Pulse.Syntax.Base.tm_vprop", + "equation_Pulse.Syntax.Base.with_range", + "lemma_FStar.Reflection.Typing.inspect_pack", + "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", + "typing_FStar.Reflection.Const.prop_qn", + "typing_FStar.Reflection.V2.Builtins.pack_fv", + "typing_Pulse.Syntax.Base.tm_vprop" + ], + 0, + "5381d3c42d4596e2c3e0232763ca69a1" + ], + [ + "Pulse.Typing.Metatheory.Base.tot_typing_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "51c2f31483fad94fe46ebe1737735495" + ], + [ + "Pulse.Typing.Metatheory.Base.st_typing_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "3530e7ff140c115907addadc565aa81d" + ], + [ + "Pulse.Typing.Metatheory.Base.veq_weakening", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_3aba1e2499c7e2419418a981cbb95c4a", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" + ], + 0, + "16cbe1999178dd0dd9df7b1ebd52e5eb" + ], + [ + "Pulse.Typing.Metatheory.Base.st_typing_subst", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "disc_equation_Pulse.Syntax.Base.C_Tot", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.comp_st", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.Env.singleton_env", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", + "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", + "refinement_interpretation_Tm_refine_7c7d00e0760f324c8ab1d3479743b399", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.singleton_env" + ], + 0, + "f2e89b82b8fc12fba38e97b77345f7fd" + ], + [ + "Pulse.Typing.Metatheory.Base.vprop_equiv_subst", + 1, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "bool_inversion", + "equation_FStar.Reflection.V2.Data.var", + "equation_FStar.Set.disjoint", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.dom", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.Env.singleton_env", + "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", + "kinding_Pulse.Syntax.Base.term@tok", + "lemma_FStar.Map.lemma_ContainsDom", + "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.lemma_equal_elim", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", + "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_fstar_env", + "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", + "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", + "refinement_interpretation_Tm_refine_7c7d00e0760f324c8ab1d3479743b399", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", + "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.singleton_env" + ], + 0, + "e25136e9b9ae3d34808fc358f0a341db" + ], + [ + "Pulse.Typing.Metatheory.Base.vprop_equiv_subst", + 2, + 2, + 1, + [ + "@MaxIFuel_assumption", "@query", "equation_Prims.nat", + "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.disjoint", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_Pulse.Typing.Env.singleton_env", + "refinement_interpretation_Tm_refine_7c7d00e0760f324c8ab1d3479743b399" + ], + 0, + "db06c345628a9b895eb18531998c908a" + ] + ] +] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.fst b/lib/steel/pulse/Pulse.Typing.Metatheory.fst index 821ba41bc..c5546d0d9 100644 --- a/lib/steel/pulse/Pulse.Typing.Metatheory.fst +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.fst @@ -1,686 +1,63 @@ module Pulse.Typing.Metatheory + open Pulse.Syntax -open Pulse.Syntax.Naming open Pulse.Typing -let admit_st_comp_typing (g:env) (st:st_comp) - : st_comp_typing g st - = admit(); - STC g st (fresh g) (admit()) (admit()) (admit()) - -let admit_comp_typing (g:env) (c:comp_st) - : comp_typing_u g c - = match c with - | C_ST st -> - CT_ST g st (admit_st_comp_typing g st) - | C_STAtomic inames st -> - CT_STAtomic g inames st (admit()) (admit_st_comp_typing g st) - | C_STGhost inames st -> - CT_STGhost g inames st (admit()) (admit_st_comp_typing g st) - -let st_typing_correctness (#g:env) (#t:st_term) (#c:comp_st) - (_:st_typing g t c) - : comp_typing_u g c - = admit_comp_typing g c - -let add_frame_well_typed (#g:env) (#c:comp_st) (ct:comp_typing_u g c) - (#f:term) (ft:tot_typing g f tm_vprop) - : comp_typing_u g (add_frame c f) - = admit_comp_typing _ _ - -let comp_typing_inversion #g #c ct = - match ct with - | CT_ST _ _ st - | CT_STAtomic _ _ _ _ st - | CT_STGhost _ _ _ _ st -> st - -let st_comp_typing_inversion_cofinite (#g:env) (#st:_) (ct:st_comp_typing g st) = - admit(), admit(), (fun _ -> admit()) +module T = FStar.Tactics.V2 -let st_comp_typing_inversion (#g:env) (#st:_) (ct:st_comp_typing g st) = - let STC g st x ty pre post = ct in - (| ty, pre, x, post |) +let tot_typing_weakening_single _ _ _ = admit () -let tm_exists_inversion (#g:env) (#u:universe) (#ty:term) (#p:term) - (_:tot_typing g (tm_exists_sl u (as_binder ty) p) tm_vprop) - (x:var { fresh_wrt x g (freevars p) } ) - : universe_of g ty u & - tot_typing (push_binding g x ppname_default ty) p tm_vprop - = admit(), admit() - -let tot_typing_weakening +let st_typing_weakening (g:env) (g':env { disjoint g g' }) - (t:term) (ty:term) (_:tot_typing (push_env g g') t ty) - (g1:env { pairwise_disjoint g g1 g' }) - : tot_typing (push_env (push_env g g1) g') t ty - = admit () - -let tot_typing_weakening1 #g #t #ty x x_t d = - let empty_g = mk_env (fstar_env g) in - let singl_g = push_binding empty_g x ppname_default x_t in - tot_typing_weakening g empty_g t ty d singl_g - -let pure_typing_inversion (#g:env) (#p:term) (_:tot_typing g (tm_pure p) tm_vprop) - : tot_typing g p (tm_fstar FStar.Reflection.Typing.tm_prop Range.range_0) - = admit () - -let non_informative_t_weakening (g g':env) (g1:env{ pairwise_disjoint g g1 g' }) - (u:universe) (t:term) - (d:non_informative_t (push_env g g') u t) - : non_informative_t (push_env (push_env g g1) g') u t = - let (| w, _ |) = d in - (| w, magic () |) - -let non_informative_c_weakening (g g':env) (g1:env{ pairwise_disjoint g g1 g' }) - (c:comp_st) - (d:non_informative_c (push_env g g') c) - : non_informative_c (push_env (push_env g g1) g') c = - non_informative_t_weakening g g' g1 _ _ d - -let bind_comp_weakening (g:env) (g':env { disjoint g g' }) - (#x:var) (#c1 #c2 #c3:comp) (d:bind_comp (push_env g g') x c1 c2 c3) - (g1:env { pairwise_disjoint g g1 g' }) - : Tot (bind_comp (push_env (push_env g g1) g') x c1 c2 c3) - (decreases d) = - - match d with - | Bind_comp _ x c1 c2 _ _ _ -> - assume (None? (lookup (push_env g g1) x)); - let y = fresh (push_env (push_env g g1) g') in - assume (~ (y `Set.mem` (freevars (comp_post c2)))); - Bind_comp _ x c1 c2 (magic ()) y (magic ()) - - | Bind_comp_ghost_l _ x c1 c2 n_d _ _ _ -> - assume (None? (lookup (push_env g g1) x)); - let y = fresh (push_env (push_env g g1) g') in - assume (~ (y `Set.mem` (freevars (comp_post c2)))); - Bind_comp_ghost_l _ x c1 c2 (non_informative_c_weakening g g' g1 _ n_d) (magic ()) y (magic ()) - - | Bind_comp_ghost_r _ x c1 c2 n_d _ _ _ -> - assume (None? (lookup (push_env g g1) x)); - let y = fresh (push_env (push_env g g1) g') in - assume (~ (y `Set.mem` (freevars (comp_post c2)))); - Bind_comp_ghost_r _ x c1 c2 (non_informative_c_weakening g g' g1 _ n_d) (magic ()) y (magic ()) - -let lift_comp_weakening (g:env) (g':env { disjoint g g'}) - (#c1 #c2:comp) (d:lift_comp (push_env g g') c1 c2) - (g1:env { pairwise_disjoint g g1 g' }) - : Tot (lift_comp (push_env (push_env g g1) g') c1 c2) - (decreases d) = - - match d with - | Lift_STAtomic_ST _ c -> Lift_STAtomic_ST _ c - | Lift_STGhost_STAtomic _ c non_informative_c -> - Lift_STGhost_STAtomic _ c (non_informative_c_weakening g g' g1 _ non_informative_c) - -let st_equiv_weakening (g:env) (g':env { disjoint g g' }) - (#c1 #c2:comp) (d:st_equiv (push_env g g') c1 c2) - (g1:env { pairwise_disjoint g g1 g' }) - : st_equiv (push_env (push_env g g1) g') c1 c2 = - match d with - | ST_VPropEquiv _ c1 c2 x _ _ _ _ _ -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - ST_VPropEquiv _ c1 c2 x (magic ()) (magic ()) (magic ()) (magic ()) (magic ()) - -let st_comp_typing_weakening (g:env) (g':env { disjoint g g' }) - (#s:st_comp) (d:st_comp_typing (push_env g g') s) - (g1:env { pairwise_disjoint g g1 g' }) - : st_comp_typing (push_env (push_env g g1) g') s = - match d with - | STC _ st x _ _ _ -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - STC _ st x (magic ()) (magic ()) (magic ()) - -let comp_typing_weakening (g:env) (g':env { disjoint g g' }) - (#c:comp) (#u:universe) (d:comp_typing (push_env g g') c u) - (g1:env { pairwise_disjoint g g1 g' }) - : comp_typing (push_env (push_env g g1) g') c u = - match d with - | CT_Tot _ t u _ -> CT_Tot _ t u (magic ()) - | CT_ST _ _ d -> CT_ST _ _ (st_comp_typing_weakening g g' d g1) - | CT_STAtomic _ inames _ _ d -> - CT_STAtomic _ inames _ (magic ()) (st_comp_typing_weakening g g' d g1) - | CT_STGhost _ inames _ _ d -> - CT_STGhost _ inames _ (magic ()) (st_comp_typing_weakening g g' d g1) - -// TODO: add precondition that g1 extends g' -let prop_validity_token_weakening (#g:env) (#t:term) - (token:prop_validity g t) - (g1:env) - : prop_validity g1 t = - admit (); - token - -val weaken_brs_typing + (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) + (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) + : st_typing (push_env g1 g') t c = + + let g2 = diff g1 g in + let d = st_typing_weakening g g' t c d g2 in + assert (equal (push_env (push_env g g2) g') (push_env g1 g')); + d + +let st_typing_weakening_standard + (#g:env) (#t:st_term) (#c:comp) (d:st_typing g t c) + (g1:env { g1 `env_extends` g }) + : st_typing g1 t c = + + let g' = mk_env (fstar_env g) in + assert (equal (push_env g g') g); + let d = st_typing_weakening g g' t c d g1 in + assert (equal (push_env g1 g') g1); + d + +let st_typing_weakening_end (g:env) (g':env { disjoint g g' }) - (g1:env { pairwise_disjoint g g1 g' }) - (#sc_u : universe) (#sc_ty : typ) (#sc : term) - (#brs : list branch) - (#c : comp_st) - (d : brs_typing (push_env g g') sc_u sc_ty sc brs c) - : brs_typing (push_env (push_env g g1) g') sc_u sc_ty sc brs c - -val weaken_br_typing + (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) + (g'':env { g'' `env_extends` g' /\ disjoint g'' g }) + : st_typing (push_env g g'') t c = + + let g2 = diff g'' g' in + let emp_env = mk_env (fstar_env g) in + assert (equal (push_env g g') + (push_env (push_env g g') emp_env)); + let d + : st_typing (push_env (push_env (push_env g g') g2) emp_env) _ _ + = Pulse.Typing.Metatheory.Base.st_typing_weakening (push_env g g') emp_env t c (coerce_eq () d) g2 in + assert (equal (push_env (push_env (push_env g g') g2) emp_env) + (push_env (push_env g g') g2)); + push_env_assoc g g' g2; + assert (equal (push_env (push_env g g') g2) + (push_env g (push_env g' g2))); + assert (equal (push_env g (push_env g' g2)) + (push_env g g'')); + coerce_eq () d + +let veq_weakening (g:env) (g':env { disjoint g g' }) - (g1:env { pairwise_disjoint g g1 g' }) - (#sc_u : universe) (#sc_ty : typ) (#sc : term) - (#p:pattern) - (#e:st_term) - (#c : comp_st) - (d : br_typing (push_env g g') sc_u sc_ty sc p e c) - : br_typing (push_env (push_env g g1) g') sc_u sc_ty sc p e c - -#push-options "--z3rlimit_factor 4 --fuel 1 --ifuel 1" -let rec st_typing_weakening g g' t c d g1 - : Tot (st_typing (push_env (push_env g g1) g') t c) - (decreases d) = - - match d with - | T_Abs _ _ _ _ _ _ _ _ _ -> - // T_Abs is used only at the top, should not come up - magic () - - | T_STApp _ head ty q res arg _ _ -> - T_STApp _ head ty q res arg (magic ()) (magic ()) - - | T_Return _ c use_eq u t e post x_old _ _ _ -> - let x = fresh (push_env (push_env g g1) g') in - assume (~ (x `Set.mem` freevars post)); - // x is only used to open and then close - assume (comp_return c use_eq u t e post x_old == - comp_return c use_eq u t e post x); - T_Return _ c use_eq u t e post x (magic ()) (magic ()) (magic ()) - - | T_Lift _ e c1 c2 d_c1 d_lift -> - T_Lift _ e c1 c2 (st_typing_weakening g g' e c1 d_c1 g1) - (lift_comp_weakening g g' d_lift g1) - - | T_Bind _ e1 e2 c1 c2 b x c d_e1 _ d_e2 d_bc -> - let d_e1 : st_typing (push_env (push_env g g1) g') e1 c1 = - st_typing_weakening g g' e1 c1 d_e1 g1 in - // - // When we call it, g' will actually be empty - // And they way bind checker invokes the lemma, we also know x is not in g1 - // But we must fix it cleanly - // Perhaps typing rules should take a thunk, fun (x:var) ... - // - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - let d_e2 - : st_typing (push_binding (push_env g g') x ppname_default (comp_res c1)) - (open_st_term_nv e2 (b.binder_ppname, x)) - c2 = d_e2 in - assert (equal (push_binding (push_env g g') x ppname_default (comp_res c1)) - (push_env g (push_binding g' x ppname_default (comp_res c1)))); - let d_e2 - : st_typing (push_env g (push_binding g' x ppname_default (comp_res c1))) - (open_st_term_nv e2 (b.binder_ppname, x)) - c2 = d_e2 in - let d_e2 - : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default (comp_res c1))) - (open_st_term_nv e2 (b.binder_ppname, x)) - c2 = st_typing_weakening g (push_binding g' x ppname_default (comp_res c1)) _ _ d_e2 g1 in - assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default (comp_res c1))) - (push_binding (push_env (push_env g g1) g') x ppname_default (comp_res c1))); - let d_e2 - : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default (comp_res c1)) - (open_st_term_nv e2 (b.binder_ppname, x)) - c2 = d_e2 in - let d_bc = bind_comp_weakening g g' d_bc g1 in - T_Bind _ e1 e2 c1 c2 b x c d_e1 (magic ()) d_e2 d_bc - - | T_TotBind _ e1 e2 t1 c2 x _ d_e2 -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - let d_e2 - : st_typing (push_binding (push_env g g') x ppname_default t1) - (open_st_term_nv e2 (v_as_nv x)) - c2 = d_e2 in - assert (equal (push_binding (push_env g g') x ppname_default t1) - (push_env g (push_binding g' x ppname_default t1))); - let d_e2 - : st_typing (push_env g (push_binding g' x ppname_default t1)) - (open_st_term_nv e2 (v_as_nv x)) - c2 = d_e2 in - let d_e2 - : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default t1)) - (open_st_term_nv e2 (v_as_nv x)) - c2 = st_typing_weakening g (push_binding g' x ppname_default t1) _ _ d_e2 g1 in - assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default t1)) - (push_binding (push_env (push_env g g1) g') x ppname_default t1)); - let d_e2 - : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default t1) - (open_st_term_nv e2 (v_as_nv x)) - c2 = d_e2 in - - T_TotBind _ e1 e2 t1 c2 x (magic ()) d_e2 - - | T_If _ b e1 e2 c uc hyp _ d_e1 d_e2 _ -> - assume (~ (hyp `Set.mem` dom g')); - assume (~ (hyp `Set.mem` dom g1)); - let d_e1 - : st_typing (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) - e1 c = d_e1 in - assert (equal (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) - (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)))); - let d_e1 - : st_typing (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) - e1 c = d_e1 in - let d_e1 - : st_typing (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) - e1 c = st_typing_weakening g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) _ _ d_e1 g1 in - assert (equal (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))) - (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true))); - let d_e1 - : st_typing (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) - e1 c = d_e1 in - let d_e2 - : st_typing (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) - e2 c = d_e2 in - assert (equal (push_binding (push_env g g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) - (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)))); - let d_e2 - : st_typing (push_env g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) - e2 c = d_e2 in - let d_e2 - : st_typing (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) - e2 c = st_typing_weakening g (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) _ _ d_e2 g1 in - assert (equal (push_env (push_env g g1) (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))) - (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false))); - let d_e2 - : st_typing (push_binding (push_env (push_env g g1) g') hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) - e2 c = d_e2 in - - T_If _ b e1 e2 c uc hyp (magic ()) d_e1 d_e2 (magic ()) - - | T_Match _ sc_u sc_ty sc d_sc_ty d_sc c brs d_brs d_pats_complete -> - admit(); - T_Match (push_env (push_env g g1) g') - sc_u sc_ty sc - (tot_typing_weakening g g' _ _ d_sc_ty g1) - (tot_typing_weakening g g' _ _ d_sc g1) - c brs - (weaken_brs_typing g g' g1 d_brs) - d_pats_complete // admit above for this - - | T_Frame _ e c frame _ d_e -> - T_Frame _ e c frame (magic ()) (st_typing_weakening g g' e c d_e g1) - - | T_Equiv _ e c c' d_e d_eq -> - T_Equiv _ e c c' (st_typing_weakening g g' e c d_e g1) (st_equiv_weakening g g' d_eq g1) - - | T_IntroPure _ p _ token -> T_IntroPure _ p (magic ()) (prop_validity_token_weakening token _) - - | T_ElimExists _ u t p x _ _ -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - T_ElimExists _ u t p x (magic ()) (magic ()) - - | T_IntroExists _ u b p e _ _ _ -> - T_IntroExists _ u b p e (magic ()) (magic ()) (magic ()) - - | T_IntroExistsErased _ u b p e _ _ _ -> - T_IntroExistsErased _ u b p e (magic ()) (magic ()) (magic ()) - - | T_While _ inv cond body _ cond_typing body_typing -> - T_While _ inv cond body (magic ()) - (st_typing_weakening g g' cond (comp_while_cond ppname_default inv) cond_typing g1) - (st_typing_weakening g g' body (comp_while_body ppname_default inv) body_typing g1) - - | T_Par _ eL cL eR cR x cL_typing cR_typing eL_typing eR_typing -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - T_Par _ eL cL eR cR x - (comp_typing_weakening g g' cL_typing g1) - (comp_typing_weakening g g' cR_typing g1) - (st_typing_weakening g g' eL cL eL_typing g1) - (st_typing_weakening g g' eR cR eR_typing g1) - - | T_WithLocal _ init body init_t c x _ _ d_c d_body -> - assume (~ (x `Set.mem` dom g')); - assume (~ (x `Set.mem` dom g1)); - let d_body - : st_typing (push_binding (push_env g g') x ppname_default (mk_ref init_t)) - (open_st_term_nv body (v_as_nv x)) - (comp_withlocal_body x init_t init c) = d_body in - assert (equal (push_binding (push_env g g') x ppname_default (mk_ref init_t)) - (push_env g (push_binding g' x ppname_default (mk_ref init_t)))); - let d_body - : st_typing (push_env g (push_binding g' x ppname_default (mk_ref init_t))) - (open_st_term_nv body (v_as_nv x)) - (comp_withlocal_body x init_t init c) = d_body in - let d_body - : st_typing (push_env (push_env g g1) (push_binding g' x ppname_default (mk_ref init_t))) - (open_st_term_nv body (v_as_nv x)) - (comp_withlocal_body x init_t init c) - = st_typing_weakening g (push_binding g' x ppname_default (mk_ref init_t)) _ _ d_body g1 in - assert (equal (push_env (push_env g g1) (push_binding g' x ppname_default (mk_ref init_t))) - (push_binding (push_env (push_env g g1) g') x ppname_default (mk_ref init_t))); - let d_body - : st_typing (push_binding (push_env (push_env g g1) g') x ppname_default (mk_ref init_t)) - (open_st_term_nv body (v_as_nv x)) - (comp_withlocal_body x init_t init c) = d_body in - T_WithLocal _ init body init_t c x (magic ()) (magic ()) - (comp_typing_weakening g g' d_c g1) - d_body - - | T_Rewrite _ p q _ _ -> T_Rewrite _ p q (magic ()) (magic ()) - - | T_Admit _ s c d_s -> T_Admit _ s c (st_comp_typing_weakening g g' d_s g1) - -and weaken_brs_typing g g' g1 #sc_u #sc_ty #sc #brs #c - (d : brs_typing (push_env g g') sc_u sc_ty sc brs c) - : Tot (brs_typing (push_env (push_env g g1) g') sc_u sc_ty sc brs c) - (decreases d) -= - match d with - | TBRS_0 c -> TBRS_0 c - | TBRS_1 c p e brd rest rest_d -> - TBRS_1 c p e (weaken_br_typing g g' g1 #sc_u #sc_ty #sc #p #e #c brd) rest (weaken_brs_typing g g' g1 rest_d) - -and weaken_br_typing g g' g1 #sc_u #sc_ty #sc #p #e #c - (d : br_typing (push_env g g') sc_u sc_ty sc p e c) - : Tot (br_typing (push_env (push_env g g1) g') sc_u sc_ty sc p e c) - (decreases d) -= - let TBR _ sc_u sc_ty sc c p e bs _ _ _ hyp d = d in - admit (); // TODO - TBR (push_env (push_env g g1) g') sc_u sc_ty sc c p e bs () () () hyp - (st_typing_weakening g g' _ _ d g1) - -#pop-options - -#push-options "--admit_smt_queries true" -let rec subst_env (en:env) (ss:subst) - : en':env { fstar_env en == fstar_env en' /\ - dom en == dom en' } = - match bindings en with - | [] -> en - | _ -> - let x, t, en = remove_latest_binding en in - push_binding (subst_env en ss) x ppname_default (subst_term t ss) - -let non_informative_t_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (u:universe) (t1:term) - (d:non_informative_t (push_env g (push_env (singleton_env (fstar_env g) x t) g')) u t1) - - : non_informative_t (push_env g (subst_env g' (nt x e))) u (subst_term t1 (nt x e)) = - - let ss = nt x e in - - let (| w, _ |) = d in - (| subst_term w ss, magic () |) - -let non_informative_c_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (c:comp) - (d:non_informative_c (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c) - - : non_informative_c (push_env g (subst_env g' (nt x e))) (subst_comp c (nt x e)) = - - non_informative_t_subst g x t g' e_typing _ _ d - -let lift_comp_subst - (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#c1 #c2:comp) - (d:lift_comp (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c1 c2) - - : lift_comp (push_env g (subst_env g' (nt x e))) - (subst_comp c1 (nt x e)) - (subst_comp c2 (nt x e)) = - - let ss = nt x e in - - match d with - | Lift_STAtomic_ST _ c -> - Lift_STAtomic_ST _ (subst_comp c ss) - - | Lift_STGhost_STAtomic _ c d_non_informative -> - Lift_STGhost_STAtomic _ (subst_comp c ss) - (non_informative_c_subst g x t g' e_typing _ d_non_informative) - -let bind_comp_subst - (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#y:var) (#c1 #c2 #c3:comp) (d:bind_comp (push_env g (push_env (singleton_env (fstar_env g) x t) g')) y c1 c2 c3) - : bind_comp (push_env g (subst_env g' (nt x e))) - y - (subst_comp c1 (nt x e)) - (subst_comp c2 (nt x e)) - (subst_comp c3 (nt x e)) = - - let ss = nt x e in - - match d with - | Bind_comp _ y c1 c2 _ z _ -> - Bind_comp _ y (subst_comp c1 ss) - (subst_comp c2 ss) - (magic ()) - z - (magic ()) - - | Bind_comp_ghost_l _ y c1 c2 d_non_informative _ z _ -> - Bind_comp_ghost_l _ y (subst_comp c1 ss) - (subst_comp c2 ss) - (non_informative_c_subst g x t g' e_typing _ d_non_informative) - (magic ()) - z - (magic ()) - - | Bind_comp_ghost_r _ y c1 c2 d_non_informative _ z _ -> - Bind_comp_ghost_r _ y (subst_comp c1 ss) - (subst_comp c2 ss) - (non_informative_c_subst g x t g' e_typing _ d_non_informative) - (magic ()) - z - (magic ()) - -let st_equiv_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#c1 #c2:comp) (d:st_equiv (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c1 c2) - : st_equiv (push_env g (subst_env g' (nt x e))) - (subst_comp c1 (nt x e)) - (subst_comp c2 (nt x e)) = - match d with - | ST_VPropEquiv _ c1 c2 y _ _ _ _ _ -> - ST_VPropEquiv _ (subst_comp c1 (nt x e)) - (subst_comp c2 (nt x e)) - y - (magic ()) - (magic ()) - (magic ()) - (magic ()) - (magic ()) - -let st_comp_typing_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#s:st_comp) (d:st_comp_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) s) - : st_comp_typing (push_env g (subst_env g' (nt x e))) - (subst_st_comp s (nt x e)) = - match d with - | STC _ s y _ _ _ -> - STC _ (subst_st_comp s (nt x e)) - y - (magic ()) - (magic ()) - (magic ()) - -let comp_typing_subst (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#c:comp) (#u:universe) (d:comp_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) c u) - : comp_typing (push_env g (subst_env g' (nt x e))) - (subst_comp c (nt x e)) u = - match d with - | CT_Tot _ t u _ -> - CT_Tot _ (subst_term t (nt x e)) u (magic ()) - | CT_ST _ s d_s -> - CT_ST _ (subst_st_comp s (nt x e)) (st_comp_typing_subst g x t g' e_typing d_s) - | CT_STAtomic _ inames s _ d_s -> - CT_STAtomic _ inames (subst_st_comp s (nt x e)) (magic ()) (st_comp_typing_subst g x t g' e_typing d_s) - | CT_STGhost _ inames s _ d_s -> - CT_STGhost _ inames (subst_st_comp s (nt x e)) (magic ()) (st_comp_typing_subst g x t g' e_typing d_s) - - -let coerce_eq (#a #b:Type) (x:a) (_:squash (a == b)) : y:b { y == x } = x - -let rec st_typing_subst g x t g' #e e_typing #e1 #c1 e1_typing - : Tot (st_typing (push_env g (subst_env g' (nt x e))) - (subst_st_term e1 (nt x e)) - (subst_comp c1 (nt x e))) - (decreases e1_typing) = - - let ss = nt x e in - - match e1_typing with - | T_Abs _ _ _ _ _ _ _ _ _ -> magic () - - | T_STApp _ head ty q res arg _ _ -> - T_STApp _ (subst_term head ss) - (subst_term ty ss) - q - (subst_comp res ss) - (subst_term arg ss) - (magic ()) - (magic ()) - - | T_Return _ c use_eq u t e post x _ _ _ -> - T_Return _ c use_eq u - (subst_term t ss) - (subst_term e ss) - (subst_term post ss) - x - (magic ()) - (magic ()) - (magic ()) - - | T_Lift _ e c1 c2 d_e d_lift -> - T_Lift _ (subst_st_term e ss) - (subst_comp c1 ss) - (subst_comp c2 ss) - (st_typing_subst g x t g' e_typing d_e) - (lift_comp_subst g x t g' e_typing d_lift) - - | T_Bind _ e1 e2 c1 c2 b y c d_e1 _ d_e2 d_bc -> - T_Bind _ (subst_st_term e1 ss) - (subst_st_term e2 ss) - (subst_comp c1 ss) - (subst_comp c2 ss) - (subst_binder b ss) - y - (subst_comp c ss) - (st_typing_subst g x t g' e_typing d_e1) - (magic ()) - (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default (comp_res c1)) e_typing d_e2) ()) - (bind_comp_subst g x t g' e_typing d_bc) - - | T_TotBind _ e1 e2 t1 c2 y _ d_e2 -> - T_TotBind _ (subst_term e1 ss) - (subst_st_term e2 ss) - (subst_term t1 ss) - (subst_comp c2 ss) - y - (magic ()) - (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default t1) e_typing d_e2) ()) - - | T_If _ b e1 e2 c uc hyp _ d_e1 d_e2 _ -> - T_If _ (subst_term b ss) - (subst_st_term e1 ss) - (subst_st_term e2 ss) - (subst_comp c ss) - uc - hyp - (magic ()) - (coerce_eq (st_typing_subst g x t (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_true)) e_typing d_e1) ()) - (coerce_eq (st_typing_subst g x t (push_binding g' hyp ppname_default (mk_eq2 u0 tm_bool b tm_false)) e_typing d_e2) ()) - (magic ()) - - | T_Match _ _ _ _ _ _ _ _ _ _ -> magic () - - | T_Frame _ e c frame _ d_e -> - T_Frame _ (subst_st_term e ss) - (subst_comp c ss) - (subst_term frame ss) - (magic ()) - (st_typing_subst g x t g' e_typing d_e) - - | T_Equiv _ e c c' d_e d_eq -> - T_Equiv _ (subst_st_term e ss) - (subst_comp c ss) - (subst_comp c' ss) - (st_typing_subst g x t g' e_typing d_e) - (st_equiv_subst g x t g' e_typing d_eq) - - | T_IntroPure _ p _ _ -> - T_IntroPure _ (subst_term p ss) - (magic ()) - (magic ()) - - | T_ElimExists _ u t p y _ _ -> - T_ElimExists _ u (subst_term t ss) (subst_term p ss) y (magic ()) (magic ()) - - | T_IntroExists _ u b p e _ _ _ -> - T_IntroExists _ u (subst_binder b ss) - (subst_term p ss) - (subst_term e ss) - (magic ()) - (magic ()) - (magic ()) - - | T_IntroExistsErased _ u b p e _ _ _ -> - T_IntroExistsErased _ u (subst_binder b ss) - (subst_term p ss) - (subst_term e ss) - (magic ()) - (magic ()) - (magic ()) - - | T_While _ inv cond body _ cond_typing body_typing -> - T_While _ (subst_term inv ss) - (subst_st_term cond ss) - (subst_st_term body ss) - (magic ()) - (st_typing_subst g x t g' e_typing cond_typing) - (st_typing_subst g x t g' e_typing body_typing) - - | T_Par _ eL cL eR cR y d_cL d_cR d_eL d_eR -> - T_Par _ (subst_st_term eL ss) - (subst_comp cL ss) - (subst_st_term eR ss) - (subst_comp cR ss) - y - (comp_typing_subst g x t g' e_typing d_cL) - (comp_typing_subst g x t g' e_typing d_cR) - (st_typing_subst g x t g' e_typing d_eL) - (st_typing_subst g x t g' e_typing d_eR) - - | T_WithLocal _ init body init_t c y _ _ d_c d_body -> - T_WithLocal _ (subst_term init ss) - (subst_st_term body ss) - (subst_term init_t ss) - (subst_comp c ss) - y - (magic ()) - (magic ()) - (comp_typing_subst g x t g' e_typing d_c) - (coerce_eq (st_typing_subst g x t (push_binding g' y ppname_default (mk_ref init_t)) e_typing d_body) ()) - - | T_Rewrite _ p q _ _ -> - T_Rewrite _ (subst_term p ss) - (subst_term q ss) - (magic ()) - (magic ()) - - | T_Admit _ s c d_s -> - T_Admit _ (subst_st_comp s ss) c (st_comp_typing_subst g x t g' e_typing d_s) -#pop-options + (#v1 #v2:vprop) (d:vprop_equiv (push_env g g') v1 v2) + (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) + : vprop_equiv (push_env g1 g') v1 v2 = + + let g2 = diff g1 g in + let d = Pulse.Typing.Metatheory.Base.veq_weakening g g' d g2 in + assert (equal (push_env (push_env g g2) g') (push_env g1 g')); + d diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.fst.hints b/lib/steel/pulse/Pulse.Typing.Metatheory.fst.hints index 049b25946..4097400cf 100644 --- a/lib/steel/pulse/Pulse.Typing.Metatheory.fst.hints +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.fst.hints @@ -1,787 +1,62 @@ [ - "j&\u001ffd!\f\u0011\u0006 \u0013N", + "\u0002\bXZc=Չ_;", [ [ - "Pulse.Typing.Metatheory.comp_typing_u", + "Pulse.Typing.Metatheory.tot_typing_weakening_single", 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "725aef6c4cd40ffbe291cf3ab513e097" - ], - [ - "Pulse.Typing.Metatheory.admit_comp_typing", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.comp_u", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "9871739a1529c615aff41dd7175b237f" - ], - [ - "Pulse.Typing.Metatheory.comp_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "3d7065fe1bcf372e84f7d114c945cef6" - ], - [ - "Pulse.Typing.Metatheory.comp_typing_inversion", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", - "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "constructor_distinct_Pulse.Syntax.Base.C_Tot", - "data_elim_Pulse.Typing.CT_ST", "data_elim_Pulse.Typing.CT_STAtomic", - "data_elim_Pulse.Typing.CT_STGhost", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "disc_equation_Pulse.Typing.CT_ST", - "disc_equation_Pulse.Typing.CT_STAtomic", - "disc_equation_Pulse.Typing.CT_STGhost", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.comp_u", - "equation_Pulse.Syntax.Base.st_comp_of_comp", - "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Typing.Metatheory.comp_typing_u", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Typing.comp_typing", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", - "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "projection_inverse_Pulse.Syntax.Base.C_Tot__0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "9a570ea75337687fe4670a0512046485" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion_cofinite", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "ae57042592df606172616177f7a03d63" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion_cofinite", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "73b3b6ba3dd0b28a5875e50b335dfd02" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "094569f812add28b3be8233ac2232818" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Typing.STC", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.ppname_default", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Syntax.Naming.open_term", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "proj_equation_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_Pulse.Typing.STC_g", - "projection_inverse_Pulse.Typing.STC_st", - "projection_inverse_Pulse.Typing.STC_x", - "refinement_interpretation_Tm_refine_6067909eb7e26441b043722acc4cd3cf", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "5725e11382c88da7e95f8e115d3c27da" - ], - [ - "Pulse.Typing.Metatheory.tm_exists_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "060e5e0a5f3fc62cdc8ef2299a20f43b" - ], - [ - "Pulse.Typing.Metatheory.tm_exists_inversion", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_Pulse.Typing.Env.as_map" - ], - 0, - "1d56383ce8115532894431c0c7459cb6" - ], - [ - "Pulse.Typing.Metatheory.tot_typing_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", - "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_356d7afdfe093fa68350ffe4fb20df1e", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "ce78b62bb516f54f1f69e588fafefcb1" - ], - [ - "Pulse.Typing.Metatheory.tot_typing_weakening", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", - "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" - ], - 0, - "1d9968c09b0fce5d9b57a1b4b0ce6cba" - ], - [ - "Pulse.Typing.Metatheory.tot_typing_weakening", - 3, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_356d7afdfe093fa68350ffe4fb20df1e", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "586b8535666de9f65684b1bdbafcec83" - ], - [ - "Pulse.Typing.Metatheory.pure_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", - "data_elim_Pulse.Syntax.Base.Mkterm", - "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", - "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", - "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", - "equation_FStar.Reflection.Types.name", - "equation_FStar.Reflection.Typing.tm_prop", - "equation_Pulse.Syntax.Base.not_tv_unknown", - "equation_Pulse.Syntax.Base.range", - "equation_Pulse.Syntax.Base.tm_vprop", - "equation_Pulse.Syntax.Base.with_range", - "lemma_FStar.Reflection.Typing.inspect_pack", - "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "typing_FStar.Reflection.Const.prop_qn", - "typing_FStar.Reflection.V2.Builtins.pack_fv", - "typing_Pulse.Syntax.Base.tm_vprop" - ], - 0, - "7145f8167c31a2e9a6ee764942501020" - ], - [ - "Pulse.Typing.Metatheory.pure_typing_inversion", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", - "data_elim_Pulse.Syntax.Base.Mkterm", - "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", - "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", - "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", - "equation_FStar.Reflection.Types.name", - "equation_FStar.Reflection.Typing.tm_prop", - "equation_Pulse.Syntax.Base.not_tv_unknown", - "equation_Pulse.Syntax.Base.range", - "equation_Pulse.Syntax.Base.tm_vprop", - "equation_Pulse.Syntax.Base.with_range", - "lemma_FStar.Reflection.Typing.inspect_pack", - "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "typing_FStar.Reflection.Const.prop_qn", - "typing_FStar.Reflection.V2.Builtins.pack_fv", - "typing_Pulse.Syntax.Base.tm_vprop" - ], - 0, - "3978fc73c096745ad025c48e564d6082" - ], - [ - "Pulse.Typing.Metatheory.comp_st_with_post", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", - "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "data_elim_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.st_comp_of_comp", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", - "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "1af5a0d50a29c08466d5ac1ac02372be" - ], - [ - "Pulse.Typing.Metatheory.comp_st_with_pre", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", - "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "615dd9ff35c89df193f5c24479e37e21" - ], - [ - "Pulse.Typing.Metatheory.non_informative_t_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8" - ], - 0, - "f7cb590b1a27ec00abe09c94cc3c3f9f" - ], - [ - "Pulse.Typing.Metatheory.non_informative_t_weakening", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "894127b1d5f205d654fd52e3fc7fc745" - ], - [ - "Pulse.Typing.Metatheory.non_informative_c_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8" - ], - 0, - "5e3b08c129d43947ba3e266175250e20" - ], - [ - "Pulse.Typing.Metatheory.non_informative_c_weakening", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "571ae1e86704f1da882f27f6824825ed" - ], - [ - "Pulse.Typing.Metatheory.bind_comp_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "Pulse.Syntax.Base_pretyping_b015b044c5bf00a3dd3df9fa711c87dd", - "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Typing.Bind_comp", - "data_elim_Pulse.Typing.Bind_comp_ghost_l", - "data_elim_Pulse.Typing.Bind_comp_ghost_r", - "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "disc_equation_Pulse.Typing.Bind_comp", - "disc_equation_Pulse.Typing.Bind_comp_ghost_l", - "disc_equation_Pulse.Typing.Bind_comp_ghost_r", - "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.bind_comp_ghost_l_compatible", - "equation_Pulse.Typing.bind_comp_ghost_l_pre", - "equation_Pulse.Typing.bind_comp_ghost_r_compatible", - "equation_Pulse.Typing.bind_comp_ghost_r_pre", "false_interp", - "fuel_guarded_inversion_FStar.Pervasives.Native.option", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Typing.bind_comp", - "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "int_typing", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Map.lemma_SelConcat1", - "lemma_FStar.Set.disjoint_not_in_both", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_2b6798c0823f5b5055723c1967d93598", - "refinement_interpretation_Tm_refine_2f458fa5f654138dcffb245813d49f42", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_4f650fc2932b3d31e01200d48fa18e08", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_611ba448e793150e81181c9e427cdb95", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "refinement_interpretation_Tm_refine_fecc77b374a5a63ebf9e46c0cac6c2d5", - "typing_FStar.Map.contains", "typing_FStar.Map.domain", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.lookup" + "@MaxIFuel_assumption", "@query", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", + "function_token_typing_Prims.int", + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "b8c4f1fba90b720a3bd53de52562acc9" + "ce7d00c38f76240f436badda65d1998a" ], [ - "Pulse.Typing.Metatheory.lift_comp_weakening", - 1, + "Pulse.Typing.Metatheory.tot_typing_weakening_single", 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Typing.Lift_STAtomic_ST", - "data_elim_Pulse.Typing.Lift_STGhost_STAtomic", - "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_Pulse.Typing.Lift_STAtomic_ST", - "disc_equation_Pulse.Typing.Lift_STGhost_STAtomic", - "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "fuel_guarded_inversion_Pulse.Typing.lift_comp", - "function_token_typing_Prims.__cache_version_number__", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env" - ], - 0, - "33f41f6618270aff87d70ffc6ffa2d7e" - ], - [ - "Pulse.Typing.Metatheory.st_equiv_weakening", - 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "constructor_distinct_Tm_unit", - "data_elim_Pulse.Typing.ST_VPropEquiv", - "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_res", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.ppname_default", - "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.st_equiv_pre", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", - "fuel_guarded_inversion_Pulse.Typing.st_equiv", + "@MaxIFuel_assumption", "@query", "equation_Prims.eqtype", + "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "proj_equation_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_Pulse.Typing.ST_VPropEquiv_c1", - "projection_inverse_Pulse.Typing.ST_VPropEquiv_c2", - "projection_inverse_Pulse.Typing.ST_VPropEquiv_x", - "refinement_interpretation_Tm_refine_28c4a39499c4c8364ff6badb936a6446", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_5ecc2896a3c67fb3a0af5aa92f4f89a7", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.empty", "typing_FStar.Set.intersect", - "typing_FStar.Set.mem", "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.push_env" + "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "c7a885291755a5edfd7f4f234aa19d2e" + "787d87ddf047743acdbdb9fc212335e1" ], [ - "Pulse.Typing.Metatheory.st_comp_typing_weakening", + "Pulse.Typing.Metatheory.st_typing_weakening", 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Typing.STC", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.ppname_default", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Syntax.Base.vprop", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "fuel_guarded_inversion_FStar.Pervasives.Native.option", - "fuel_guarded_inversion_Pulse.Typing.st_comp_typing", - "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "int_typing", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "proj_equation_FStar.Pervasives.Native.Mktuple2__2", - "proj_equation_Pulse.Syntax.Base.Mkst_comp_post", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_Pulse.Typing.STC_st", - "projection_inverse_Pulse.Typing.STC_x", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_6067909eb7e26441b043722acc4cd3cf", - "typing_FStar.Map.contains", "typing_FStar.Reflection.V2.Data.var", - "typing_FStar.Set.empty", "typing_FStar.Set.intersect", - "typing_FStar.Set.mem", - "typing_Pulse.Syntax.Base.__proj__Mkst_comp__item__post", - "typing_Pulse.Syntax.Naming.freevars", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.lookup", "typing_Pulse.Typing.Env.push_env" + "@MaxIFuel_assumption", "@query", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" ], 0, - "35727cb765baa907d3896ef490f6817f" + "a2de9df58b7a04c94ccde5a47e0269b1" ], [ - "Pulse.Typing.Metatheory.comp_typing_weakening", - 1, + "Pulse.Typing.Metatheory.st_typing_weakening", + 2, 2, 1, [ "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "data_elim_Pulse.Typing.CT_ST", "data_elim_Pulse.Typing.CT_STAtomic", - "data_elim_Pulse.Typing.CT_STGhost", "data_elim_Pulse.Typing.CT_Tot", - "disc_equation_Pulse.Typing.CT_ST", - "disc_equation_Pulse.Typing.CT_STAtomic", - "disc_equation_Pulse.Typing.CT_STGhost", - "disc_equation_Pulse.Typing.CT_Tot", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "fuel_guarded_inversion_Pulse.Typing.comp_typing", "int_inversion", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.equal", + "equation_Pulse.Typing.Env.extends_with", + "equation_Pulse.Typing.Env.pairwise_disjoint", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", @@ -789,452 +64,186 @@ "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" ], 0, - "0135ffde0c6a6c3737cbc196edc7b967" + "362bd1bdb698dcd91ccec6d49e1ecdc6" ], [ - "Pulse.Typing.Metatheory.st_typing_weakening", + "Pulse.Typing.Metatheory.st_typing_weakening_standard", 1, - 1, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "5a67cde77a42abfac62958b304a3e367" - ], - [ - "Pulse.Typing.Metatheory.st_typing_weakening", 2, 1, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_6cccd4061358a25e815eb84acc173fa0", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "68d64a62e79dde1384d08cc565e208ac" - ], - [ - "Pulse.Typing.Metatheory.st_typing_weakening", - 3, - 1, - 1, [ "@MaxFuel_assumption", "@MaxIFuel_assumption", "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", - "@fuel_correspondence_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", - "@fuel_irrelevance_FStar.List.Tot.Base.append.fuel_instrumented", - "@query", "Prims_pretyping_ce036b6b736ef4e0bc3a9ff132a12aed", - "binder_x_01e6cbbfeab3ba416b144f2c9223a2d4_2", - "binder_x_1ad99e5433effa849e32ef9adfa111a0_0", - "binder_x_253c3a680f4c9d78f6acd0325daa4c3c_1", - "binder_x_7112683412d09ec447176f925f3fb12f_4", - "binder_x_fb0ca6e2d7f75ea984e10bb2482a9563_5", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.None", - "constructor_distinct_FStar.Pervasives.Native.Some", - "constructor_distinct_Prims.Cons", - "data_elim_Pulse.Syntax.Base.Mkppname", - "data_elim_Pulse.Typing.ST_VPropEquiv", - "data_elim_Pulse.Typing.T_Admit", "data_elim_Pulse.Typing.T_Bind", - "data_elim_Pulse.Typing.T_ElimExists", - "data_elim_Pulse.Typing.T_Equiv", "data_elim_Pulse.Typing.T_Frame", - "data_elim_Pulse.Typing.T_If", - "data_elim_Pulse.Typing.T_IntroExists", - "data_elim_Pulse.Typing.T_IntroExistsErased", - "data_elim_Pulse.Typing.T_IntroPure", - "data_elim_Pulse.Typing.T_Lift", "data_elim_Pulse.Typing.T_Par", - "data_elim_Pulse.Typing.T_Return", - "data_elim_Pulse.Typing.T_Rewrite", "data_elim_Pulse.Typing.T_STApp", - "data_elim_Pulse.Typing.T_TotBind", "data_elim_Pulse.Typing.T_While", - "data_elim_Pulse.Typing.T_WithLocal", - "disc_equation_FStar.Pervasives.Native.None", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "disc_equation_Pulse.Typing.T_Abs", - "disc_equation_Pulse.Typing.T_Admit", - "disc_equation_Pulse.Typing.T_Bind", - "disc_equation_Pulse.Typing.T_ElimExists", - "disc_equation_Pulse.Typing.T_Equiv", - "disc_equation_Pulse.Typing.T_Frame", - "disc_equation_Pulse.Typing.T_If", - "disc_equation_Pulse.Typing.T_IntroExists", - "disc_equation_Pulse.Typing.T_IntroExistsErased", - "disc_equation_Pulse.Typing.T_IntroPure", - "disc_equation_Pulse.Typing.T_Lift", - "disc_equation_Pulse.Typing.T_Match", - "disc_equation_Pulse.Typing.T_Par", - "disc_equation_Pulse.Typing.T_Return", - "disc_equation_Pulse.Typing.T_Rewrite", - "disc_equation_Pulse.Typing.T_STApp", - "disc_equation_Pulse.Typing.T_TotBind", - "disc_equation_Pulse.Typing.T_While", - "disc_equation_Pulse.Typing.T_WithLocal", + "@query", "bool_inversion", "constructor_distinct_Prims.Nil", "equation_FStar.List.Tot.Base.op_At", - "equation_FStar.Pervasives.Native.fst", - "equation_FStar.Pervasives.Native.snd", - "equation_FStar.Reflection.Typing.fstar_env", - "equation_FStar.Reflection.Typing.fstar_env_fvs", - "equation_FStar.Reflection.Typing.fstar_top_env", - "equation_FStar.Reflection.Typing.pp_name_t", "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Sealed.Inhabited.sealed", - "equation_FStar.Sealed.Inhabited.sealed_", - "equation_FStar.Set.disjoint", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.comp_res", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.nvar", - "equation_Pulse.Syntax.Base.ppname_default", - "equation_Pulse.Syntax.Base.range", - "equation_Pulse.Syntax.Base.stateful_comp", - "equation_Pulse.Syntax.Base.typ", - "equation_Pulse.Syntax.Base.v_as_nv", + "equation_FStar.Set.disjoint", "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.env_bindings", + "equation_Pulse.Typing.Env.env_extends", "equation_Pulse.Typing.Env.equal", - "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.mk_eq2", "equation_Pulse.Typing.mk_ref", + "equation_Pulse.Typing.Env.extends_with", "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", - "equation_with_fuel_Pulse.Syntax.Naming.freevars_st.fuel_instrumented", - "fuel_guarded_inversion_FStar.Pervasives.Native.option", - "fuel_guarded_inversion_Prims.list", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.ppname", - "fuel_guarded_inversion_Pulse.Syntax.Base.st_term", - "fuel_guarded_inversion_Pulse.Typing.st_equiv", "fuel_guarded_inversion_Pulse.Typing.st_typing", - "function_token_typing_FStar.Reflection.Types.term", - "function_token_typing_Prims.__cache_version_number__", - "function_token_typing_Prims.int", - "function_token_typing_Prims.string", "function_token_typing_Pulse.Typing.Env.binding", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", "int_inversion", - "kinding_Pulse.Syntax.Base.ppname@tok", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.List.Tot.Properties.append_l_nil", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Map.lemma_InDomUpd2", "lemma_FStar.Map.lemma_UpdDomain", - "lemma_FStar.Sealed.Inhabited.sealed_singleton", "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", - "lemma_FStar.Set.lemma_equal_refl", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_FStar.Set.mem_singleton", - "lemma_FStar.Set.mem_union", - "lemma_Pulse.Syntax.Base.range_singleton", - "lemma_Pulse.Typing.Env.equal_elim", - "lemma_Pulse.Typing.Env.push_binding_as_map", - "lemma_Pulse.Typing.Env.push_binding_bs", - "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", + "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.equal_elim", + "lemma_Pulse.Typing.Env.mk_env_bs", + "lemma_Pulse.Typing.Env.mk_env_dom", "lemma_Pulse.Typing.Env.push_env_bindings", "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "primitive_Prims.op_Equality", - "proj_equation_FStar.Pervasives.Native.Mktuple2__1", - "proj_equation_FStar.Pervasives.Native.Mktuple2__2", - "proj_equation_Pulse.Syntax.Base.Mknm_nm_ppname", - "proj_equation_Pulse.Syntax.Base.Mkppname_name", - "proj_equation_Pulse.Syntax.Base.Mkppname_range", - "projection_inverse_BoxBool_proj_0", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__1", - "projection_inverse_FStar.Pervasives.Native.Mktuple2__2", - "projection_inverse_Prims.Cons_a", - "projection_inverse_Prims.Cons_hd", - "projection_inverse_Prims.Cons_tl", - "projection_inverse_Pulse.Syntax.Base.Mknm_nm_ppname", - "refinement_interpretation_Tm_refine_00889bd3bc6adb297f9f40795de5a761", - "refinement_interpretation_Tm_refine_0e05a441736ee1a990510e8440d3b4d7", - "refinement_interpretation_Tm_refine_1e3b46ef574b7c7b56e6f48d45a4bd20", - "refinement_interpretation_Tm_refine_25fe9861b42cf97d961ff4c8f44eb399", - "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", - "refinement_interpretation_Tm_refine_28c4a39499c4c8364ff6badb936a6446", - "refinement_interpretation_Tm_refine_2ee1d1f639c54669fffde14441581c40", - "refinement_interpretation_Tm_refine_31a19f8325d7b982ed757060a8acefd0", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", - "refinement_interpretation_Tm_refine_5028deff2121e50c204ffaa83e40ed60", + "primitive_Prims.op_AmpAmp", "projection_inverse_Prims.Nil_a", + "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_65c667c598fddb3432338b957782b444", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "refinement_interpretation_Tm_refine_9047505ffccc2ed9f904ea452d789620", - "refinement_interpretation_Tm_refine_b62cb64ffa39b6d9d2eb56acf9f4cf34", - "refinement_interpretation_Tm_refine_b7f9d9ebe5d1159aa86931b8cc6b3d65", - "refinement_interpretation_Tm_refine_b9943bf670d3eeece9d9f2e3e534ed66", - "refinement_interpretation_Tm_refine_c3a8a0db088f6874b298e9191f4d6f5c", - "refinement_interpretation_Tm_refine_c985e04063fe38cddadc0a297161b419", - "refinement_interpretation_Tm_refine_d79470205dca7f56c9b5a5da9d23b961", - "refinement_interpretation_Tm_refine_f2631f1e9df7e7fe731df0b4c6310657", - "refinement_interpretation_Tm_refine_f327b3b66854e57c59289f8c259581e7", - "refinement_kinding_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "string_typing", "subterm_ordering_Pulse.Typing.T_Bind", - "subterm_ordering_Pulse.Typing.T_Equiv", - "subterm_ordering_Pulse.Typing.T_Frame", - "subterm_ordering_Pulse.Typing.T_If", - "subterm_ordering_Pulse.Typing.T_Lift", - "subterm_ordering_Pulse.Typing.T_Par", - "subterm_ordering_Pulse.Typing.T_TotBind", - "subterm_ordering_Pulse.Typing.T_While", - "subterm_ordering_Pulse.Typing.T_WithLocal", - "typing_FStar.Map.contains", "typing_FStar.Pervasives.Native.fst", - "typing_FStar.Pervasives.Native.snd", - "typing_FStar.Pervasives.Native.uu___is_None", - "typing_FStar.Reflection.Typing.bool_fv", - "typing_FStar.Reflection.Typing.lookup_fvar", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Sealed.seal", - "typing_FStar.Set.empty", "typing_FStar.Set.intersect", - "typing_FStar.Set.mem", "typing_FStar.Set.singleton", - "typing_FStar.Set.union", - "typing_Pulse.Syntax.Base.__proj__Mkbinder__item__binder_ppname", - "typing_Pulse.Syntax.Base.__proj__Mkppname__item__name", - "typing_Pulse.Syntax.Base.__proj__Mkppname__item__range", - "typing_Pulse.Syntax.Base.comp_res", - "typing_Pulse.Syntax.Base.ppname_default", - "typing_Pulse.Syntax.Base.uu___is_C_ST", - "typing_Pulse.Syntax.Base.v_as_nv", - "typing_Pulse.Syntax.Naming.freevars_st", - "typing_Pulse.Syntax.Pure.u0", "typing_Pulse.Typing.Env.as_map", + "refinement_interpretation_Tm_refine_7ad5682d990eaec6510764d663af54de", + "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", + "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.bindings", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Env.lookup", - "typing_Pulse.Typing.Env.push_binding", - "typing_Pulse.Typing.Env.push_env", "typing_Pulse.Typing.mk_eq2", - "typing_Pulse.Typing.mk_ref", "typing_Pulse.Typing.tm_bool", - "typing_Pulse.Typing.tm_false", "typing_Pulse.Typing.tm_true" + "typing_Pulse.Typing.Env.fstar_env", "typing_Pulse.Typing.Env.mk_env" ], 0, - "0199cb8eea38ade73b67f0bbde75778c" + "57e0569f3c5b0b66d4f26ef8ebfc15f1" ], [ - "Pulse.Typing.Metatheory.veq_weakening", - 1, + "Pulse.Typing.Metatheory.st_typing_weakening_end", 1, + 2, 1, [ "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", + "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "254d3fa9398b30aa89c7c40991c69d26" - ], - [ - "Pulse.Typing.Metatheory.singleton_env", - 1, - 1, - 1, - [ - "@query", "equation_FStar.Reflection.V2.Data.var", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", - "lemma_FStar.Set.mem_empty", "lemma_Pulse.Typing.Env.mk_env_dom", - "typing_FStar.Reflection.V2.Data.var" + "typing_Pulse.Typing.Env.dom" ], 0, - "e2d01c94f71242dd599db139c7af3051" + "656ab0be259a067261a03469eaea01fb" ], [ - "Pulse.Typing.Metatheory.subst_env", - 1, + "Pulse.Typing.Metatheory.st_typing_weakening_end", 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", - "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" - ], - 0, - "3f34c911b195009d59bf0f5810a2dccb" - ], - [ - "Pulse.Typing.Metatheory.st_typing_subst", - 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", + "@MaxFuel_assumption", "@MaxIFuel_assumption", + "@fuel_correspondence_FStar.List.Tot.Base.append.fuel_instrumented", + "@query", "bool_inversion", "constructor_distinct_Prims.Nil", + "equation_FStar.List.Tot.Base.op_At", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Typing.Env.binding", "equation_Pulse.Typing.Env.disjoint", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", + "equation_Pulse.Typing.Env.env_bindings", + "equation_Pulse.Typing.Env.env_extends", + "equation_Pulse.Typing.Env.equal", + "equation_Pulse.Typing.Env.extends_with", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "equation_with_fuel_FStar.List.Tot.Base.append.fuel_instrumented", + "fuel_guarded_inversion_Pulse.Typing.st_typing", + "function_token_typing_Pulse.Typing.Env.binding", "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", + "lemma_FStar.Set.disjoint_not_in_both", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", + "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.equal_elim", + "lemma_Pulse.Typing.Env.mk_env_bs", + "lemma_Pulse.Typing.Env.mk_env_dom", "lemma_Pulse.Typing.Env.push_env_as_map", + "lemma_Pulse.Typing.Env.push_env_bindings", "lemma_Pulse.Typing.Env.push_env_fstar_env", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "projection_inverse_Prims.Nil_a", + "refinement_interpretation_Tm_refine_30687c6bbf76a4ea67eae131536eafd7", + "refinement_interpretation_Tm_refine_484fe0819d1383a2c20d94ae027baa5f", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.singleton_env" + "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.bindings", + "typing_Pulse.Typing.Env.dom", "typing_Pulse.Typing.Env.fstar_env", + "typing_Pulse.Typing.Env.mk_env", "typing_Pulse.Typing.Env.push_env" ], 0, - "d4cbc07157d9009d5cb5518a0b788c9c" + "9e3450e2d49793dca6b6321bacdb3bca" ], [ - "Pulse.Typing.Metatheory.st_typing_subst", - 2, + "Pulse.Typing.Metatheory.veq_weakening", + 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f" + "@MaxIFuel_assumption", "@query", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" ], 0, - "81c54fd13c73cab83f75f9a4b30caa4a" + "78db82acf32ede0c864ce70ba096bc73" ], [ - "Pulse.Typing.Metatheory.vprop_equiv_subst", - 1, + "Pulse.Typing.Metatheory.veq_weakening", + 2, 2, 1, [ "@MaxIFuel_assumption", "@query", "bool_inversion", + "constructor_distinct_FStar.Pervasives.Native.Some", + "disc_equation_FStar.Pervasives.Native.None", + "equation_FStar.Reflection.Typing.fstar_top_env", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", + "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.equal", + "equation_Pulse.Typing.Env.extends_with", + "equation_Pulse.Typing.Env.pairwise_disjoint", + "function_token_typing_Prims.__cache_version_number__", + "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", "lemma_FStar.Map.lemma_ContainsDom", "lemma_FStar.Map.lemma_InDomConcat", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", + "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", + "refinement_interpretation_Tm_refine_262f039a938fc14ac016e995f8cd074e", "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.singleton_env" - ], - 0, - "ac9f94d892af32315a0badfae95d1855" - ], - [ - "Pulse.Typing.Metatheory.vprop_equiv_subst", - 2, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f" + "typing_Pulse.Typing.Env.fstar_env" ], 0, - "96e2864565aa229ecdac0907f982f991" + "c9d5b51c7a6209a7d74068ad8ddebd22" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.fsti b/lib/steel/pulse/Pulse.Typing.Metatheory.fsti index d361e9235..f0f46e1f9 100644 --- a/lib/steel/pulse/Pulse.Typing.Metatheory.fsti +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.fsti @@ -3,108 +3,34 @@ open Pulse.Syntax open Pulse.Syntax.Naming open Pulse.Typing -let comp_typing_u (g:env) (c:comp_st) = comp_typing g c (comp_u c) +include Pulse.Typing.Metatheory.Base -val admit_comp_typing (g:env) (c:comp_st) - : comp_typing_u g c - -val st_typing_correctness (#g:env) (#t:st_term) (#c:comp_st) - (_:st_typing g t c) - : comp_typing_u g c - -val comp_typing_inversion (#g:env) (#c:comp_st) (ct:comp_typing_u g c) - : st_comp_typing g (st_comp_of_comp c) - -val st_comp_typing_inversion_cofinite (#g:env) (#st:_) (ct:st_comp_typing g st) - : (universe_of g st.res st.u & - tot_typing g st.pre tm_vprop & - (x:var{fresh_wrt x g (freevars st.post)} -> //this part is tricky, to get the quantification on x - tot_typing (push_binding g x ppname_default st.res) (open_term st.post x) tm_vprop)) - -val st_comp_typing_inversion (#g:env) (#st:_) (ct:st_comp_typing g st) - : (universe_of g st.res st.u & - tot_typing g st.pre tm_vprop & - x:var{fresh_wrt x g (freevars st.post)} & - tot_typing (push_binding g x ppname_default st.res) (open_term st.post x) tm_vprop) - -val tm_exists_inversion (#g:env) (#u:universe) (#ty:term) (#p:term) - (_:tot_typing g (tm_exists_sl u (as_binder ty) p) tm_vprop) - (x:var { fresh_wrt x g (freevars p) } ) - : universe_of g ty u & - tot_typing (push_binding g x ppname_default ty) p tm_vprop - -let pairwise_disjoint (g g' g'':env) = - disjoint g g' /\ disjoint g' g'' /\ disjoint g g'' - -val tot_typing_weakening - (g:env) (g':env { disjoint g g' }) - (t:term) (ty:term) (_:tot_typing (push_env g g') t ty) - (g1:env { pairwise_disjoint g g1 g' }) - : tot_typing (push_env (push_env g g1) g') t ty - -val tot_typing_weakening1 - (#g:env) (#t:term) (#ty:term) - (x:var { fresh_wrt x g Set.empty }) +val tot_typing_weakening_single (#g:env) (#t #ty:term) + (d:tot_typing g t ty) + (x:var { ~ (x `Set.mem` dom g)}) (x_t:typ) - (_:tot_typing g t ty) - : tot_typing (push_binding g x ppname_default x_t) t ty - -val pure_typing_inversion (#g:env) (#p:term) (_:tot_typing g (tm_pure p) tm_vprop) - : tot_typing g p (tm_fstar FStar.Reflection.Typing.tm_prop Range.range_0) - -let comp_st_with_post (c:comp_st) (post:term) : c':comp_st { st_comp_of_comp c' == ({ st_comp_of_comp c with post} <: st_comp) } = - match c with - | C_ST st -> C_ST { st with post } - | C_STGhost i st -> C_STGhost i { st with post } - | C_STAtomic i st -> C_STAtomic i {st with post} - -let comp_st_with_pre (c:comp_st) (pre:term) : comp_st = - match c with - | C_ST st -> C_ST { st with pre } - | C_STGhost i st -> C_STGhost i { st with pre } - | C_STAtomic i st -> C_STAtomic i {st with pre } + : tot_typing (push_binding g x ppname_default x_t) t ty val st_typing_weakening (g:env) (g':env { disjoint g g' }) - (t:st_term) (c:comp) (_:st_typing (push_env g g') t c) - (g1:env { pairwise_disjoint g g1 g' }) - : st_typing (push_env (push_env g g1) g') t c - -let veq_weakening - (g:env) (g':env { disjoint g g' }) - (#v1 #v2:vprop) (_:vprop_equiv (push_env g g') v1 v2) - (g1:env { pairwise_disjoint g g1 g' }) - : vprop_equiv (push_env (push_env g g1) g') v1 v2 = magic () - -// move to Env -let singleton_env (f:_) (x:var) (t:typ) = push_binding (mk_env f) x ppname_default t + (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) + (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) + : st_typing (push_env g1 g') t c -let nt (x:var) (t:term) = [ NT x t ] +val st_typing_weakening_standard + (#g:env) (#t:st_term) (#c:comp) (d:st_typing g t c) + (g1:env { g1 `env_extends` g }) + : st_typing g1 t c -val subst_env (en:env) (ss:subst) - : en':env { fstar_env en == fstar_env en' /\ - dom en == dom en' } - -val st_typing_subst - (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#e1:st_term) (#c1:comp_st) - (e1_typing:st_typing (push_env g (push_env (singleton_env (fstar_env g) x t) g')) e1 c1) - - : st_typing (push_env g (subst_env g' (nt x e))) - (subst_st_term e1 (nt x e)) - (subst_comp c1 (nt x e)) - -let vprop_equiv_subst - (g:env) (x:var) (t:typ) (g':env { pairwise_disjoint g (singleton_env (fstar_env g) x t) g' }) - (#e:term) - (e_typing:tot_typing g e t) - (#p1:term) (#p2:term) - (veq:vprop_equiv (push_env g (push_env (singleton_env (fstar_env g) x t) g')) p1 p2) +val st_typing_weakening_end + (g:env) (g':env { disjoint g g' }) + (t:st_term) (c:comp) (d:st_typing (push_env g g') t c) + (g'':env { g'' `env_extends` g' /\ disjoint g'' g }) + : st_typing (push_env g g'') t c -: vprop_equiv (push_env g (subst_env g' (nt x e))) - (subst_term p1 (nt x e)) - (subst_term p2 (nt x e)) = - admit () +val veq_weakening + (g:env) (g':env { disjoint g g' }) + (#v1 #v2:vprop) (d:vprop_equiv (push_env g g') v1 v2) + (g1:env { g1 `env_extends` g /\ disjoint g1 g' }) + : vprop_equiv (push_env g1 g') v1 v2 diff --git a/lib/steel/pulse/Pulse.Typing.Metatheory.fsti.hints b/lib/steel/pulse/Pulse.Typing.Metatheory.fsti.hints index e258737bd..e0c18fc88 100644 --- a/lib/steel/pulse/Pulse.Typing.Metatheory.fsti.hints +++ b/lib/steel/pulse/Pulse.Typing.Metatheory.fsti.hints @@ -1,305 +1,8 @@ [ - "JJ*':Mqsu\u0011", + ",x>mI\u0015", [ [ - "Pulse.Typing.Metatheory.comp_typing_u", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "1b8336cc8894b86ac3af5aa83386c4cc" - ], - [ - "Pulse.Typing.Metatheory.comp_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "5ab99c4ac0af08422d88aaef00843707" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion_cofinite", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "5d5e7594596379280b2bd365dded2d48" - ], - [ - "Pulse.Typing.Metatheory.st_comp_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_c66fdd97364ac13701a9ea2a206028a8", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "b27b4126daebb5ea01effba7aa6912b8" - ], - [ - "Pulse.Typing.Metatheory.tm_exists_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.dom", "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_5decb6aa26ec21455bdbf1ef967a5856", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "788dc67acbbd2c8f53e86a069bcda036" - ], - [ - "Pulse.Typing.Metatheory.tot_typing_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "disc_equation_FStar.Pervasives.Native.None", - "equation_FStar.Reflection.V2.Data.var", "equation_Prims.eqtype", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.typ", - "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Env.lookup", - "equation_Pulse.Typing.fresh_wrt", "function_token_typing_Prims.int", - "haseqTm_refine_542f9d4f129664613f2483a6c88bc7c2", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_356d7afdfe093fa68350ffe4fb20df1e", - "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "19499076a776cd1a3f0486bc3b4caaad" - ], - [ - "Pulse.Typing.Metatheory.pure_typing_inversion", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_FVar", - "constructor_distinct_FStar.Reflection.V2.Data.Tv_Unknown", - "data_elim_Pulse.Syntax.Base.Mkterm", - "data_typing_intro_FStar.Reflection.V2.Data.Tv_FVar@tok", - "equality_tok_FStar.Reflection.V2.Data.Tv_Unknown@tok", - "equality_tok_Pulse.Syntax.Base.Tm_VProp@tok", - "equation_FStar.Reflection.Types.name", - "equation_FStar.Reflection.Typing.tm_prop", - "equation_Pulse.Syntax.Base.not_tv_unknown", - "equation_Pulse.Syntax.Base.range", - "equation_Pulse.Syntax.Base.tm_vprop", - "equation_Pulse.Syntax.Base.with_range", - "lemma_FStar.Reflection.Typing.inspect_pack", - "refinement_interpretation_Tm_refine_8c22aa61a47c16d0229ef090894097c8", - "typing_FStar.Reflection.Const.prop_qn", - "typing_FStar.Reflection.V2.Builtins.pack_fv", - "typing_Pulse.Syntax.Base.tm_vprop" - ], - 0, - "7a4651690b38bb056f1d4ee211e2d617" - ], - [ - "Pulse.Typing.Metatheory.comp_st_with_post", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", - "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "data_elim_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.st_comp_of_comp", - "equation_Pulse.Syntax.Base.stateful_comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", - "primitive_Prims.op_BarBar", "projection_inverse_BoxBool_proj_0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__0", - "projection_inverse_Pulse.Syntax.Base.C_STAtomic__1", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__0", - "projection_inverse_Pulse.Syntax.Base.C_STGhost__1", - "projection_inverse_Pulse.Syntax.Base.C_ST__0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "1754ba3f8776e76f6a61731c9df87731" - ], - [ - "Pulse.Typing.Metatheory.comp_st_with_pre", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", - "constructor_distinct_Pulse.Syntax.Base.C_ST", - "constructor_distinct_Pulse.Syntax.Base.C_STAtomic", - "constructor_distinct_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_ST", - "disc_equation_Pulse.Syntax.Base.C_STAtomic", - "disc_equation_Pulse.Syntax.Base.C_STGhost", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_Pulse.Syntax.Base.comp_st", - "fuel_guarded_inversion_Pulse.Syntax.Base.comp", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a" - ], - 0, - "615dd9ff35c89df193f5c24479e37e21" - ], - [ - "Pulse.Typing.Metatheory.st_typing_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "bd6e48bef996a3ea2172a39ee52bed5d" - ], - [ - "Pulse.Typing.Metatheory.veq_weakening", - 1, - 2, - 1, - [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "constructor_distinct_FStar.Pervasives.Native.Some", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "int_inversion", "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_478810302d3261f456fa9b0eb16ba8e8", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom" - ], - 0, - "522fb02559a00f3828aa9a8c0b8c46a3" - ], - [ - "Pulse.Typing.Metatheory.singleton_env", - 1, - 2, - 1, - [ - "@query", "equation_FStar.Reflection.V2.Data.var", - "equation_Prims.nat", "equation_Pulse.Syntax.Base.var", - "lemma_FStar.Set.mem_empty", "lemma_Pulse.Typing.Env.mk_env_dom", - "typing_FStar.Reflection.V2.Data.var" - ], - 0, - "6f440ae7cc1d76b0dee82d84cbea23d1" - ], - [ - "Pulse.Typing.Metatheory.subst_env", + "Pulse.Typing.Metatheory.tot_typing_weakening_single", 1, 2, 1, @@ -311,51 +14,22 @@ "refinement_interpretation_Tm_refine_414d0a9f578ab0048252f8c8f552b99f" ], 0, - "b2326395bdde0021b500c945fa383461" + "d956953603bdee068aa6f354b59eedbd" ], [ - "Pulse.Typing.Metatheory.st_typing_subst", + "Pulse.Typing.Metatheory.st_typing_weakening", 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "bool_inversion", - "disc_equation_Pulse.Syntax.Base.C_Tot", - "equation_FStar.Reflection.V2.Data.var", - "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.comp_st", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", - "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", - "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", - "refinement_interpretation_Tm_refine_78cf9fabb706bab7e54de904b7db9d2a", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f", - "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", - "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.singleton_env" + "@MaxIFuel_assumption", "@query", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" ], 0, - "9f864fbb005e9b65dffbe8834b93ab50" + "e7ab244afcc1f3afdbcb000f2aac6d54" ], [ - "Pulse.Typing.Metatheory.vprop_equiv_subst", + "Pulse.Typing.Metatheory.st_typing_weakening_end", 1, 2, 1, @@ -363,50 +37,31 @@ "@MaxIFuel_assumption", "@query", "bool_inversion", "equation_FStar.Reflection.V2.Data.var", "equation_FStar.Set.disjoint", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.typ", "equation_Pulse.Syntax.Base.var", + "equation_Pulse.Syntax.Base.var", "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Env.dom", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "fuel_guarded_inversion_Pulse.Syntax.Base.term", "int_inversion", - "kinding_Pulse.Syntax.Base.term@tok", - "lemma_FStar.Map.lemma_ContainsDom", - "lemma_FStar.Map.lemma_InDomConcat", - "lemma_FStar.Set.lemma_equal_elim", + "equation_Pulse.Typing.Env.dom", "lemma_FStar.Set.lemma_equal_elim", "lemma_FStar.Set.lemma_equal_intro", "lemma_FStar.Set.mem_empty", - "lemma_FStar.Set.mem_intersect", "lemma_Pulse.Typing.Env.mk_env_dom", - "lemma_Pulse.Typing.Env.push_env_as_map", - "lemma_Pulse.Typing.Env.push_env_fstar_env", - "primitive_Prims.op_AmpAmp", "primitive_Prims.op_BarBar", + "lemma_FStar.Set.mem_intersect", "primitive_Prims.op_AmpAmp", "projection_inverse_BoxBool_proj_0", - "refinement_interpretation_Tm_refine_530c8dba59115f16314c44e7c3c4f062", - "refinement_interpretation_Tm_refine_542f9d4f129664613f2483a6c88bc7c2", - "refinement_interpretation_Tm_refine_5640c3b1e6dbb4f6537716200df8bd14", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab", "typing_FStar.Reflection.V2.Data.var", "typing_FStar.Set.empty", "typing_FStar.Set.intersect", "typing_FStar.Set.mem", - "typing_Pulse.Typing.Env.as_map", "typing_Pulse.Typing.Env.dom", - "typing_Pulse.Typing.Env.fstar_env", - "typing_Pulse.Typing.Metatheory.singleton_env" + "typing_Pulse.Typing.Env.dom" ], 0, - "143959838ad0d6bf4e4fcc6c1973dd50" + "1de85b8e50579c769e74c7ec9c75ad8a" ], [ - "Pulse.Typing.Metatheory.vprop_equiv_subst", - 2, + "Pulse.Typing.Metatheory.veq_weakening", + 1, 2, 1, [ - "@MaxIFuel_assumption", "@query", "equation_Prims.nat", - "equation_Pulse.Syntax.Base.var", - "equation_Pulse.Typing.Env.disjoint", - "equation_Pulse.Typing.Metatheory.pairwise_disjoint", - "equation_Pulse.Typing.Metatheory.singleton_env", - "refinement_interpretation_Tm_refine_d0cbf185f53471ab94597d0f4191e07f" + "@MaxIFuel_assumption", "@query", + "refinement_interpretation_Tm_refine_dd3396f06b5a01f3df9ed905e57d2aab" ], 0, - "96e2864565aa229ecdac0907f982f991" + "2f67cdea47a82000e15ff8d222dd8f20" ] ] ] \ No newline at end of file diff --git a/lib/steel/pulse/Pulse.Typing.fst.hints b/lib/steel/pulse/Pulse.Typing.fst.hints index 66f5690ce..1546135be 100644 --- a/lib/steel/pulse/Pulse.Typing.fst.hints +++ b/lib/steel/pulse/Pulse.Typing.fst.hints @@ -11,7 +11,7 @@ "fuel_guarded_inversion_FStar.Tactics.Result.__result" ], 0, - "6f5656193b339ba8f3fe01636e7b297d" + "bd47f093a5144a716970e4acf048ce94" ], [ "Pulse.Typing.tm_prop", diff --git a/share/steel/examples/pulse/CustomSyntax.fst b/share/steel/examples/pulse/CustomSyntax.fst index 3b8f45dd7..09b80e821 100755 --- a/share/steel/examples/pulse/CustomSyntax.fst +++ b/share/steel/examples/pulse/CustomSyntax.fst @@ -12,6 +12,9 @@ open Pulse.Steel.Wrapper #push-options "--using_facts_from 'Prims FStar.Pervasives FStar.UInt FStar.UInt32 FStar.Ghost Pulse.Steel.Wrapper CustomSyntax'" #push-options "--ide_id_info_off" +assume val p : vprop +assume val g : unit -> stt unit emp (fun _ -> p) + let folded_pts_to (r:ref U32.t) (n:erased U32.t) : vprop = pts_to r full_perm n ```pulse @@ -43,8 +46,7 @@ fn test_read (r:ref U32.t) returns x : U32.t ensures pts_to r p x { - let x = !r; - x + !r } ``` diff --git a/share/steel/examples/steelc/HaclExample2.fst b/share/steel/examples/steelc/HaclExample2.fst index f0b7afccb..39c4dd812 100644 --- a/share/steel/examples/steelc/HaclExample2.fst +++ b/share/steel/examples/steelc/HaclExample2.fst @@ -110,10 +110,10 @@ let test (fun v' -> p `pts_to` v') (full comp v) (fun v' -> full comp v') -= let q = p `struct_field` "limbs" in += let q = struct_field p "limbs" #_ #(base_array0 five (scalar U64.t) 5sz) () in let a = array_of_base q in - let r = p `struct_field` "precomp" in - let _ = vpattern_replace_erased (pts_to p) in // FIXME: WHY WHY WHY? + let r = struct_field p "precomp" #_ #(base_array0 twenty (scalar U64.t) 20sz) () in + let _ = vpattern_replace (pts_to p) in // FIXME: WHY WHY WHY? let b = array_of_base r in let _ = do_something_with_limbs a in let _ = do_something_with_precomp b in diff --git a/share/steel/examples/steelc/LList.fst b/share/steel/examples/steelc/LList.fst index f14025af0..276c8798a 100644 --- a/share/steel/examples/steelc/LList.fst +++ b/share/steel/examples/steelc/LList.fst @@ -128,13 +128,13 @@ let push end else begin rewrite (pts_to_or_null _ _) (pts_to c (uninitialized cell)); rewrite (freeable_or_null c) (freeable c); - let p_tl = pllist_get p in - let c_hd = struct_field c "hd" in - let c_tl = struct_field c "tl" in + let p_tl : void_ptr = pllist_get p in // type ascription necessary to avoid C compiler warning -Wincompatible-pointer-types + let c_hd = struct_field c "hd" () in + let c_tl = struct_field c "tl" () in write c_hd a; write c_tl p_tl; - unstruct_field c "tl" c_tl; - unstruct_field c "hd" c_hd; + let _ = unstruct_field c "tl" c_tl in + let _ = unstruct_field c "hd" c_hd in intro_llist_cons c p_tl a l; pllist_put p c; drop (has_struct_field c "hd" _); @@ -154,13 +154,13 @@ let pop = rewrite (pllist p l) (pllist p (List.Tot.hd l :: List.Tot.tl l)); let c = pllist_get p in let _ = elim_llist_cons c (List.Tot.hd l) (List.Tot.tl l) in - let c_hd = struct_field c "hd" in - let c_tl = struct_field c "tl" in + let c_hd = struct_field c "hd" () in + let c_tl = struct_field c "tl" () in let res = read c_hd in - let p_tl = read c_tl in + let p_tl : void_ptr = read c_tl in // type ascription necessary to avoid C compiler warning -Wincompatible-pointer-types vpattern_rewrite (fun x -> llist x _) p_tl; - unstruct_field c "tl" c_tl; - unstruct_field c "hd" c_hd; + let _ = unstruct_field c "tl" c_tl in + let _ = unstruct_field c "hd" c_hd in free c; pllist_put p p_tl; drop (has_struct_field c "hd" _); diff --git a/share/steel/examples/steelc/MutualUnion.fst b/share/steel/examples/steelc/MutualUnion.fst new file mode 100644 index 000000000..4878b20bf --- /dev/null +++ b/share/steel/examples/steelc/MutualUnion.fst @@ -0,0 +1,102 @@ +module MutualUnion +open Steel.ST.Util +open Steel.ST.C.Types + +module U32 = FStar.UInt32 +module U16 = FStar.UInt16 + +(* The following correctly extracts to: +<< + +typedef union { + uint32_t as_u32; + uint16_t *as_u16; +} +MutualUnion_test_union_OK; + +>> +*) +type test_union_OK = union_t "MutualUnion.test_union_OK" ( + field_description_cons "as_u32" (scalar U32.t) ( + field_description_cons "as_u16" (scalar (ptr_gen U16.t)) ( + field_description_nil)) + ) + +(* The following extracts to something like: +<< + +typedef struct MutualUnion_test_struct_s MutualUnion_test_struct; + +typedef union { + uint32_t as_u32; + MutualUnion_test_struct *as_ptr; +} +MutualUnion_test_union1_OK; + +typedef struct MutualUnion_test_struct_s +{ + bool tag; + MutualUnion_test_union1_OK payload; +} +MutualUnion_test_struct; + +>> +*) +noeq +type test_union1_OK = union_t "MutualUnion.test_union1_OK" ( + field_description_cons "as_u32" (scalar U32.t) ( + field_description_cons "as_ptr" (scalar (ptr_gen test_struct)) ( + field_description_nil)) + ) +and test_struct = { + tag: bool; + payload: test_union1_OK; +} + +#push-options "--__no_positivity" + +(* The following extracts to something like: +<< + +typedef union MutualUnion_test_union2_OK_u MutualUnion_test_union2_OK; + +typedef struct MutualUnion_test_struct2_before_s { + bool tag; + MutualUnion_test_union2_OK *payload; +} MutualUnion_test_struct2_before; + +typedef struct MutualUnion_test_struct2_after_s MutualUnion_test_struct2_after; + +typedef union MutualUnion_test_union2_OK_u { + MutualUnion_test_struct2_before as_struct; + MutualUnion_test_struct2_after *as_ptr; +} +MutualUnion_test_union2_OK; + +typedef struct MutualUnion_test_struct2_after_s +{ + bool tag; + MutualUnion_test_union2_OK payload; +} +MutualUnion_test_struct2_after; + +>> +*) +noeq +type test_struct2_before = { + tag: bool; + payload: ptr_gen test_union2_OK; +} +and test_union2_OK = union_t "MutualUnion.test_union2_OK" ( + field_description_cons "as_struct" (scalar test_struct2_before (* TODO TR: solve positivity issue here, independently of extraction *)) ( + field_description_cons "as_ptr" (scalar (ptr_gen test_struct2_after)) ( + field_description_nil)) + ) +and test_struct2_after = { + tag: bool; + payload: test_union2_OK; +} + +#pop-options + +let test_fun () = 0s diff --git a/share/steel/examples/steelc/PointStruct.fst b/share/steel/examples/steelc/PointStruct.fst index 68023857b..62f48a9ee 100644 --- a/share/steel/examples/steelc/PointStruct.fst +++ b/share/steel/examples/steelc/PointStruct.fst @@ -40,14 +40,14 @@ let swap_struct (p: ref point) (v: Ghost.erased (typeof point)) struct_get_field v' "x" == struct_get_field v "y" /\ struct_get_field v' "y" == struct_get_field v "x" ) -= let px = struct_field p "x" in - let py = struct_field p "y" in += let px = struct_field p "x" () in + let py = struct_field p "y" () in let x = read px in let y = read py in write px y; write py x; - unstruct_field p "x" px; - unstruct_field p "y" py; + let _ = unstruct_field p "x" px in + let _ = unstruct_field p "y" py in drop (has_struct_field _ _ px); drop (has_struct_field _ _ _); return _ diff --git a/share/steel/examples/steelc/PointStructDirectDef.fst b/share/steel/examples/steelc/PointStructDirectDef.fst index e2e6d61de..9db3e93f9 100644 --- a/share/steel/examples/steelc/PointStructDirectDef.fst +++ b/share/steel/examples/steelc/PointStructDirectDef.fst @@ -27,7 +27,7 @@ let point_t = struct_t "dummy" point_fields noextract let point : typedef point_t = struct0 _ _ _ -#push-options "--query_stats --fuel 0" +#push-options "--query_stats --fuel 0 --print_implicits" let swap_struct (p: ref point) (v: Ghost.erased (typeof point)) : ST (Ghost.erased (typeof point)) @@ -40,14 +40,14 @@ let swap_struct (p: ref point) (v: Ghost.erased (typeof point)) struct_get_field v' "x" == struct_get_field v "y" /\ struct_get_field v' "y" == struct_get_field v "x" ) -= let px = struct_field p "x" in - let py = struct_field p "y" in += let px = struct_field p "x" () in + let py = struct_field p "y" () in let x = read px in let y = read py in write px y; write py x; - unstruct_field p "x" px; - unstruct_field p "y" py; + let _ = unstruct_field p "x" px in + let _ = unstruct_field p "y" py in drop (has_struct_field _ _ px); drop (has_struct_field _ _ _); return _ diff --git a/share/steel/examples/steelc/ScalarUnion.fst b/share/steel/examples/steelc/ScalarUnion.fst index a74f7e32e..428a8dcc1 100644 --- a/share/steel/examples/steelc/ScalarUnion.fst +++ b/share/steel/examples/steelc/ScalarUnion.fst @@ -46,9 +46,9 @@ val switch_to_u16 #push-options "--fuel 0 --print_bound_var_types" let switch_to_u16 p x = - let p16 = union_switch_field p "as_u16" in + let p16 = union_switch_field p "as_u16" () in write p16 x; - ununion_field p "as_u16" _; + let _ = ununion_field p "as_u16" _ in drop (has_union_field _ _ _); return () @@ -71,8 +71,8 @@ val zero_u32_of_union (#v: Ghost.erased u32_or_u16_t) (p: ref u32_or_u16) (ensures fun _ -> True) let zero_u32_of_union #v p = - let q = union_field p "as_u32" in + let q = union_field p "as_u32" () in zero_u32_ref q; - ununion_field p "as_u32" _; + let _ = ununion_field p "as_u32" _ in drop (has_union_field _ _ _); return () diff --git a/src/ocaml/plugin/generated/Pulse_Checker.ml b/src/ocaml/plugin/generated/Pulse_Checker.ml index d1f52cf98..b6cf9779e 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker.ml @@ -448,167 +448,181 @@ let rec (check : Pulse_Checker_Base.check_t) = fun pre0 -> fun pre0_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (147)) (Prims.of_int (4)) - (Prims.of_int (147)) (Prims.of_int (55))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (138)) (Prims.of_int (60)) - (Prims.of_int (254)) (Prims.of_int (50))))) - (Obj.magic (Pulse_Checker_Prover_ElimPure.elim_pure g0 pre0 ())) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple4 - (g, pre, pre_typing, k_elim_pure) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (149)) - (Prims.of_int (44)) - (Prims.of_int (250)) - (Prims.of_int (48))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (251)) (Prims.of_int (4)) - (Prims.of_int (254)) - (Prims.of_int (50))))) - (Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (150)) - (Prims.of_int (12)) - (Prims.of_int (150)) - (Prims.of_int (55))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (151)) - (Prims.of_int (4)) - (Prims.of_int (250)) - (Prims.of_int (48))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Checker_Pure.push_context - (Pulse_Syntax_Printer.tag_of_st_term - t) t.Pulse_Syntax_Base.range2 g)) - (fun uu___1 -> - (fun g1 -> - match t.Pulse_Syntax_Base.term1 with - | Pulse_Syntax_Base.Tm_Return uu___1 - -> - Obj.magic - (Obj.repr - (Pulse_Checker_Return.check - g1 pre () post_hint t)) - | Pulse_Syntax_Base.Tm_Abs uu___1 -> - Obj.magic - (Obj.repr - (FStar_Tactics_V2_Derived.fail - "Tm_Abs check should not have been called in the checker")) - | Pulse_Syntax_Base.Tm_STApp uu___1 - -> - Obj.magic - (Obj.repr - (Pulse_Checker_STApp.check - g1 pre () post_hint t)) - | Pulse_Syntax_Base.Tm_ElimExists - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Exists.check_elim_exists - g1 pre () post_hint t)) - | Pulse_Syntax_Base.Tm_IntroExists - { - Pulse_Syntax_Base.erased = - uu___1; - Pulse_Syntax_Base.p2 = p; - Pulse_Syntax_Base.witnesses = - witnesses;_} - -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (164)) - (Prims.of_int (13)) - (Prims.of_int (164)) - (Prims.of_int (46))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (164)) - (Prims.of_int (6)) - (Prims.of_int (174)) - (Prims.of_int (46))))) - (Obj.magic - (instantiate_unknown_witnesses - g1 t)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | FStar_Pervasives_Native.Some - t1 -> - Obj.magic - (check g1 + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.fst" + (Prims.of_int (148)) (Prims.of_int (4)) + (Prims.of_int (148)) (Prims.of_int (55))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.fst" + (Prims.of_int (139)) (Prims.of_int (60)) + (Prims.of_int (256)) (Prims.of_int (50))))) + (Obj.magic + (Pulse_Checker_Prover_ElimPure.elim_pure g0 pre0 ())) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | FStar_Pervasives.Mkdtuple4 + (g, pre, pre_typing, k_elim_pure) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (150)) + (Prims.of_int (44)) + (Prims.of_int (252)) + (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (253)) + (Prims.of_int (4)) + (Prims.of_int (256)) + (Prims.of_int (50))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (151)) + (Prims.of_int (12)) + (Prims.of_int (151)) + (Prims.of_int (55))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (152)) + (Prims.of_int (4)) + (Prims.of_int (252)) + (Prims.of_int (48))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Checker_Pure.push_context + (Pulse_Syntax_Printer.tag_of_st_term + t) t.Pulse_Syntax_Base.range2 + g)) + (fun uu___1 -> + (fun g1 -> + match t.Pulse_Syntax_Base.term1 + with + | Pulse_Syntax_Base.Tm_Return + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_Return.check + g1 pre () post_hint + res_ppname t)) + | Pulse_Syntax_Base.Tm_Abs uu___1 + -> + Obj.magic + (Obj.repr + (FStar_Tactics_V2_Derived.fail + "Tm_Abs check should not have been called in the checker")) + | Pulse_Syntax_Base.Tm_STApp + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_STApp.check + g1 pre () post_hint + res_ppname t)) + | Pulse_Syntax_Base.Tm_ElimExists + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_Exists.check_elim_exists + g1 pre () post_hint + res_ppname t)) + | Pulse_Syntax_Base.Tm_IntroExists + { + Pulse_Syntax_Base.erased = + uu___1; + Pulse_Syntax_Base.p2 = p; + Pulse_Syntax_Base.witnesses + = witnesses;_} + -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (165)) + (Prims.of_int (13)) + (Prims.of_int (165)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (165)) + (Prims.of_int (6)) + (Prims.of_int (175)) + (Prims.of_int (57))))) + (Obj.magic + (instantiate_unknown_witnesses + g1 t)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 + with + | FStar_Pervasives_Native.Some + t1 -> + Obj.magic + (check g1 pre () post_hint + res_ppname t1) - | FStar_Pervasives_Native.None - -> - (match witnesses - with - | [] -> + | FStar_Pervasives_Native.None + -> + (match witnesses + with + | [] -> Obj.magic (Pulse_Typing_Env.fail g1 (FStar_Pervasives_Native.Some (t.Pulse_Syntax_Base.range2)) "intro exists with empty witnesses") - | uu___3::[] + | uu___3::[] -> Obj.magic (Pulse_Checker_Exists.check_intro_exists g1 pre () post_hint + res_ppname (maybe_intro_exists_erased t) FStar_Pervasives_Native.None) - | uu___3 -> + | uu___3 -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (173)) + (Prims.of_int (174)) (Prims.of_int (19)) - (Prims.of_int (173)) + (Prims.of_int (174)) (Prims.of_int (64))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (174)) + (Prims.of_int (175)) (Prims.of_int (11)) - (Prims.of_int (174)) - (Prims.of_int (45))))) + (Prims.of_int (175)) + (Prims.of_int (56))))) (Obj.magic (transform_to_unary_intro_exists g1 p @@ -621,111 +635,117 @@ let rec (check : Pulse_Checker_Base.check_t) = (check g1 pre () post_hint + res_ppname t1)) uu___4)))) - uu___2))) - | Pulse_Syntax_Base.Tm_Bind uu___1 - -> - Obj.magic - (Obj.repr - (Pulse_Checker_Bind.check_bind - g1 pre () post_hint t - check)) - | Pulse_Syntax_Base.Tm_TotBind - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Bind.check_tot_bind - g1 pre () post_hint t - check)) - | Pulse_Syntax_Base.Tm_If - { Pulse_Syntax_Base.b1 = b; - Pulse_Syntax_Base.then_ = e1; - Pulse_Syntax_Base.else_ = e2; - Pulse_Syntax_Base.post1 = - post_if;_} - -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (183)) - (Prims.of_int (8)) - (Prims.of_int (199)) - (Prims.of_int (97))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (200)) - (Prims.of_int (8)) - (Prims.of_int (203)) - (Prims.of_int (29))))) - (match (post_if, - post_hint) - with - | (FStar_Pervasives_Native.None, - FStar_Pervasives_Native.Some - p) -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 - -> p))) - | (FStar_Pervasives_Native.Some - p, - FStar_Pervasives_Native.None) - -> - Obj.magic - (Obj.repr - (Pulse_Checker_Base.intro_post_hint - g1 - FStar_Pervasives_Native.None - FStar_Pervasives_Native.None - p)) - | (FStar_Pervasives_Native.Some - p, - FStar_Pervasives_Native.Some - q) -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + uu___2))) + | Pulse_Syntax_Base.Tm_Bind uu___1 + -> + Obj.magic + (Obj.repr + (Pulse_Checker_Bind.check_bind + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_TotBind + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_Bind.check_tot_bind + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_If + { Pulse_Syntax_Base.b1 = b; + Pulse_Syntax_Base.then_ = e1; + Pulse_Syntax_Base.else_ = e2; + Pulse_Syntax_Base.post1 = + post_if;_} + -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (184)) + (Prims.of_int (8)) + (Prims.of_int (200)) + (Prims.of_int (97))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (201)) + (Prims.of_int (8)) + (Prims.of_int (204)) + (Prims.of_int (29))))) + (match (post_if, + post_hint) + with + | (FStar_Pervasives_Native.None, + FStar_Pervasives_Native.Some + p) -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + ( + fun + uu___1 -> + p))) + | (FStar_Pervasives_Native.Some + p, + FStar_Pervasives_Native.None) + -> + Obj.magic + (Obj.repr + (Pulse_Checker_Base.intro_post_hint + g1 + FStar_Pervasives_Native.None + FStar_Pervasives_Native.None + p)) + | (FStar_Pervasives_Native.Some + p, + FStar_Pervasives_Native.Some + q) -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (189)) + (Prims.of_int (190)) (Prims.of_int (12)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (37))))) - (FStar_Sealed.seal + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (188)) + (Prims.of_int (189)) (Prims.of_int (10)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (37))))) - (Obj.magic + ( + Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (16)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (189)) + (Prims.of_int (190)) (Prims.of_int (12)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (37))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -740,17 +760,17 @@ let rec (check : Pulse_Checker_Base.check_t) = (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (189)) + (Prims.of_int (190)) (Prims.of_int (12)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (189)) + (Prims.of_int (190)) (Prims.of_int (12)) - (Prims.of_int (194)) + (Prims.of_int (195)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -758,9 +778,9 @@ let rec (check : Pulse_Checker_Base.check_t) = (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (193)) + (Prims.of_int (194)) (Prims.of_int (16)) - (Prims.of_int (193)) + (Prims.of_int (194)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic @@ -795,8 +815,9 @@ let rec (check : Pulse_Checker_Base.check_t) = uu___2 uu___1)))) uu___1))) - (fun uu___1 - -> + ( + fun + uu___1 -> (fun uu___1 -> Obj.magic @@ -806,42 +827,45 @@ let rec (check : Pulse_Checker_Base.check_t) = (t.Pulse_Syntax_Base.range2)) uu___1)) uu___1))) - | (uu___1, uu___2) -> - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g1 - (FStar_Pervasives_Native.Some + | (uu___1, uu___2) -> + Obj.magic + (Obj.repr + (Pulse_Typing_Env.fail + g1 + ( + FStar_Pervasives_Native.Some (t.Pulse_Syntax_Base.range2)) - "Pulse cannot yet infer a postcondition for a non-tail conditional statement;\nEither annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional"))) - (fun uu___1 -> - (fun post -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic + "Pulse cannot yet infer a postcondition for a non-tail conditional statement;\nEither annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional"))) + (fun uu___1 -> + (fun post -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (202)) + (Prims.of_int (203)) (Prims.of_int (8)) - (Prims.of_int (202)) - (Prims.of_int (52))))) - (FStar_Sealed.seal - (Obj.magic + (Prims.of_int (203)) + (Prims.of_int (63))))) + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (200)) + (Prims.of_int (201)) (Prims.of_int (8)) - (Prims.of_int (203)) + (Prims.of_int (204)) (Prims.of_int (29))))) - (Obj.magic - (Pulse_Checker_If.check + (Obj.magic + (Pulse_Checker_If.check g1 pre () - post b e1 - e2 check)) - (fun uu___1 - -> - FStar_Tactics_Effect.lift_div_tac + post + res_ppname + b e1 e2 + check)) + (fun uu___1 + -> + FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> match uu___1 @@ -856,101 +880,106 @@ let rec (check : Pulse_Checker_Base.check_t) = (x, t1, pre', g11, k))))) - uu___1))) - | Pulse_Syntax_Base.Tm_While uu___1 - -> - Obj.magic - (Obj.repr - (Pulse_Checker_While.check - g1 pre () post_hint t - check)) - | Pulse_Syntax_Base.Tm_Match - { Pulse_Syntax_Base.sc = sc; - Pulse_Syntax_Base.returns_ = - post_match; - Pulse_Syntax_Base.brs = brs;_} - -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (211)) - (Prims.of_int (8)) - (Prims.of_int (227)) - (Prims.of_int (97))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.fst" - (Prims.of_int (228)) - (Prims.of_int (8)) - (Prims.of_int (230)) - (Prims.of_int (30))))) - (match (post_match, - post_hint) - with - | (FStar_Pervasives_Native.None, - FStar_Pervasives_Native.Some - p) -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 - -> p))) - | (FStar_Pervasives_Native.Some - p, - FStar_Pervasives_Native.None) - -> - Obj.magic - (Obj.repr - (Pulse_Checker_Base.intro_post_hint - g1 - FStar_Pervasives_Native.None - FStar_Pervasives_Native.None - p)) - | (FStar_Pervasives_Native.Some - p, - FStar_Pervasives_Native.Some - q) -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + uu___1))) + | Pulse_Syntax_Base.Tm_While + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_While.check + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_Match + { Pulse_Syntax_Base.sc = sc; + Pulse_Syntax_Base.returns_ = + post_match; + Pulse_Syntax_Base.brs = brs;_} + -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (212)) + (Prims.of_int (8)) + (Prims.of_int (228)) + (Prims.of_int (97))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.fst" + (Prims.of_int (229)) + (Prims.of_int (8)) + (Prims.of_int (232)) + (Prims.of_int (30))))) + (match (post_match, + post_hint) + with + | (FStar_Pervasives_Native.None, + FStar_Pervasives_Native.Some + p) -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + ( + fun + uu___1 -> + p))) + | (FStar_Pervasives_Native.Some + p, + FStar_Pervasives_Native.None) + -> + Obj.magic + (Obj.repr + (Pulse_Checker_Base.intro_post_hint + g1 + FStar_Pervasives_Native.None + FStar_Pervasives_Native.None + p)) + | (FStar_Pervasives_Native.Some + p, + FStar_Pervasives_Native.Some + q) -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (217)) + (Prims.of_int (218)) (Prims.of_int (12)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (37))))) - (FStar_Sealed.seal + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (216)) + (Prims.of_int (217)) (Prims.of_int (10)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (37))))) - (Obj.magic + ( + Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (16)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (217)) + (Prims.of_int (218)) (Prims.of_int (12)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (37))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -965,17 +994,17 @@ let rec (check : Pulse_Checker_Base.check_t) = (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (217)) + (Prims.of_int (218)) (Prims.of_int (12)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (217)) + (Prims.of_int (218)) (Prims.of_int (12)) - (Prims.of_int (222)) + (Prims.of_int (223)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -983,9 +1012,9 @@ let rec (check : Pulse_Checker_Base.check_t) = (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (221)) + (Prims.of_int (222)) (Prims.of_int (16)) - (Prims.of_int (221)) + (Prims.of_int (222)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic @@ -1020,8 +1049,9 @@ let rec (check : Pulse_Checker_Base.check_t) = uu___2 uu___1)))) uu___1))) - (fun uu___1 - -> + ( + fun + uu___1 -> (fun uu___1 -> Obj.magic @@ -1031,42 +1061,45 @@ let rec (check : Pulse_Checker_Base.check_t) = (t.Pulse_Syntax_Base.range2)) uu___1)) uu___1))) - | (uu___1, uu___2) -> - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g1 - (FStar_Pervasives_Native.Some + | (uu___1, uu___2) -> + Obj.magic + (Obj.repr + (Pulse_Typing_Env.fail + g1 + ( + FStar_Pervasives_Native.Some (t.Pulse_Syntax_Base.range2)) - "Pulse cannot yet infer a postcondition for a non-tail conditional statement;\nEither annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional"))) - (fun uu___1 -> - (fun post -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic + "Pulse cannot yet infer a postcondition for a non-tail conditional statement;\nEither annotate this `if` with `returns` clause; or rewrite your code to use a tail conditional"))) + (fun uu___1 -> + (fun post -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (229)) - (Prims.of_int (37)) - (Prims.of_int (229)) - (Prims.of_int (83))))) - (FStar_Sealed.seal - (Obj.magic + (Prims.of_int (231)) + (Prims.of_int (8)) + (Prims.of_int (231)) + (Prims.of_int (65))))) + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.fst" - (Prims.of_int (228)) + (Prims.of_int (229)) (Prims.of_int (8)) - (Prims.of_int (230)) + (Prims.of_int (232)) (Prims.of_int (30))))) - (Obj.magic - (Pulse_Checker_Match.check + (Obj.magic + (Pulse_Checker_Match.check g1 pre () - post sc - brs check)) - (fun uu___1 - -> - FStar_Tactics_Effect.lift_div_tac + post + res_ppname + sc brs + check)) + (fun uu___1 + -> + FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> match uu___1 @@ -1081,58 +1114,64 @@ let rec (check : Pulse_Checker_Base.check_t) = (x, ty, pre', g11, k))))) - uu___1))) - | Pulse_Syntax_Base.Tm_ProofHintWithBinders - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_AssertWithBinders.check - g1 pre () post_hint t - check)) - | Pulse_Syntax_Base.Tm_WithLocal - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_WithLocal.check - g1 pre () post_hint t - check)) - | Pulse_Syntax_Base.Tm_Par uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Par.check g1 - pre () post_hint t check)) - | Pulse_Syntax_Base.Tm_IntroPure - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_IntroPure.check - g1 pre () post_hint t)) - | Pulse_Syntax_Base.Tm_Admit uu___1 - -> - Obj.magic - (Obj.repr - (Pulse_Checker_Admit.check - g1 pre () post_hint t)) - | Pulse_Syntax_Base.Tm_Rewrite - uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Rewrite.check - g1 pre () post_hint t)) - | uu___1 -> - Obj.magic - (Obj.repr - (FStar_Tactics_V2_Derived.fail - "Checker form not implemented"))) - uu___1))) - (fun r -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - match r with - | FStar_Pervasives.Mkdtuple5 - (x, t1, pre', g1, k) -> - FStar_Pervasives.Mkdtuple5 - (x, t1, pre', g1, - (Pulse_Checker_Base.k_elab_trans - g0 g g1 pre0 pre pre' - k_elim_pure k)))))) uu___) \ No newline at end of file + uu___1))) + | Pulse_Syntax_Base.Tm_ProofHintWithBinders + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_AssertWithBinders.check + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_WithLocal + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_WithLocal.check + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_Par uu___1 + -> + Obj.magic + (Obj.repr + (Pulse_Checker_Par.check + g1 pre () post_hint + res_ppname t check)) + | Pulse_Syntax_Base.Tm_IntroPure + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_IntroPure.check + g1 pre () post_hint + res_ppname t)) + | Pulse_Syntax_Base.Tm_Admit + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_Admit.check + g1 pre () post_hint + res_ppname t)) + | Pulse_Syntax_Base.Tm_Rewrite + uu___1 -> + Obj.magic + (Obj.repr + (Pulse_Checker_Rewrite.check + g1 pre () post_hint + res_ppname t)) + | uu___1 -> + Obj.magic + (Obj.repr + (FStar_Tactics_V2_Derived.fail + "Checker form not implemented"))) + uu___1))) + (fun r -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + match r with + | FStar_Pervasives.Mkdtuple5 + (x, g1, t1, pre', k) -> + FStar_Pervasives.Mkdtuple5 + (x, g1, t1, pre', + (Pulse_Checker_Base.k_elab_trans + g0 g g1 pre0 pre + (FStar_Pervasives.dfst pre') + k_elim_pure k)))))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Abs.ml b/src/ocaml/plugin/generated/Pulse_Checker_Abs.ml index 8785873b9..51cb38811 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Abs.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Abs.ml @@ -385,8 +385,8 @@ let rec (check_abs : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (41)) (Prims.of_int (2)) (Prims.of_int (99)) - (Prims.of_int (29))))) + (Prims.of_int (41)) (Prims.of_int (2)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> t.Pulse_Syntax_Base.range2)) (fun uu___ -> @@ -412,7 +412,7 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" (Prims.of_int (42)) (Prims.of_int (84)) - (Prims.of_int (99)) (Prims.of_int (29))))) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (Pulse_Checker_Pure.check_term g t1)) (fun uu___ -> (fun uu___ -> @@ -435,7 +435,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (45)) (Prims.of_int (41)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (Pulse_Checker_Pure.check_universe @@ -461,7 +461,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (47)) (Prims.of_int (22)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -485,7 +485,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (48)) (Prims.of_int (25)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -512,7 +512,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (49)) (Prims.of_int (53)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -544,7 +544,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (50)) (Prims.of_int (41)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -572,7 +572,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (52)) (Prims.of_int (4)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -711,7 +711,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (65)) (Prims.of_int (8)) - (Prims.of_int (72)) + (Prims.of_int (73)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic @@ -719,7 +719,7 @@ let rec (check_abs : "Pulse.Checker.Abs.fst" (Prims.of_int (63)) (Prims.of_int (10)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (match c with @@ -732,7 +732,7 @@ let rec (check_abs : g (FStar_Pervasives_Native.Some (body.Pulse_Syntax_Base.range2)) - "Tm_Abs in case of st term, C_Tot annotation")) + "Unexpected error: found a total computation annotation on a top-level function")) | uu___5 -> Obj.magic @@ -769,17 +769,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (74)) + (Prims.of_int (75)) (Prims.of_int (41)) - (Prims.of_int (74)) + (Prims.of_int (75)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (73)) + (Prims.of_int (74)) (Prims.of_int (8)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (Pulse_Checker_Pure.check_vprop @@ -802,17 +802,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (75)) + (Prims.of_int (76)) (Prims.of_int (16)) - (Prims.of_int (75)) + (Prims.of_int (76)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (75)) + (Prims.of_int (76)) (Prims.of_int (42)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -830,17 +830,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (77)) + (Prims.of_int (78)) (Prims.of_int (8)) - (Prims.of_int (84)) + (Prims.of_int (85)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (85)) + (Prims.of_int (86)) (Prims.of_int (8)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (match post_hint_body with @@ -852,7 +852,7 @@ let rec (check_abs : g (FStar_Pervasives_Native.Some (body.Pulse_Syntax_Base.range2)) - "Tm_Abs without a post hint, bailing") + "Top-level functions must be annotated with pre and post conditions") | FStar_Pervasives_Native.Some post -> @@ -862,17 +862,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (82)) + (Prims.of_int (83)) (Prims.of_int (14)) - (Prims.of_int (82)) + (Prims.of_int (83)) (Prims.of_int (130))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (84)) + (Prims.of_int (85)) (Prims.of_int (10)) - (Prims.of_int (84)) + (Prims.of_int (85)) (Prims.of_int (31))))) (Obj.magic (Pulse_Checker_Base.intro_post_hint @@ -902,22 +902,51 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (87)) + (Prims.of_int (88)) + (Prims.of_int (19)) + (Prims.of_int (88)) + (Prims.of_int (45))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Abs.fst" + (Prims.of_int (88)) + (Prims.of_int (48)) + (Prims.of_int (101)) + (Prims.of_int (29))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___7 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_fret")) + (fun + uu___7 -> + (fun + ppname1 + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Abs.fst" + (Prims.of_int (89)) (Prims.of_int (15)) - (Prims.of_int (87)) - (Prims.of_int (62))))) + (Prims.of_int (89)) + (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (87)) - (Prims.of_int (66)) - (Prims.of_int (99)) + (Prims.of_int (89)) + (Prims.of_int (73)) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (check g' pre_opened1 () post + ppname1 body_opened)) (fun uu___7 -> @@ -928,24 +957,25 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (89)) + (Prims.of_int (91)) (Prims.of_int (8)) - (Prims.of_int (89)) - (Prims.of_int (54))))) + (Prims.of_int (91)) + (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (87)) - (Prims.of_int (66)) - (Prims.of_int (99)) + (Prims.of_int (89)) + (Prims.of_int (73)) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (Pulse_Checker_Base.apply_checker_result_k g' pre_opened1 (FStar_Pervasives_Native.__proj__Some__item__v - post) r)) + post) r + ppname1)) (fun uu___7 -> (fun @@ -964,17 +994,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (91)) + (Prims.of_int (93)) (Prims.of_int (6)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (91)) + (Prims.of_int (93)) (Prims.of_int (6)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -990,17 +1020,17 @@ let rec (check_abs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (91)) + (Prims.of_int (93)) (Prims.of_int (6)) - (Prims.of_int (91)) + (Prims.of_int (93)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Abs.fst" - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (6)) - (Prims.of_int (99)) + (Prims.of_int (101)) (Prims.of_int (29))))) (Obj.magic (check_effect_annotation @@ -1023,7 +1053,7 @@ let rec (check_abs : Pulse_Syntax_Base.binder_ty = t2; Pulse_Syntax_Base.binder_ppname - = ppname + = ppname1 }; Pulse_Syntax_Base.q = qual; @@ -1042,7 +1072,7 @@ let rec (check_abs : Pulse_Syntax_Base.binder_ty = t2; Pulse_Syntax_Base.binder_ppname - = ppname + = ppname1 } qual (Pulse_Syntax_Naming.close_comp c_body x))), @@ -1053,7 +1083,7 @@ let rec (check_abs : Pulse_Syntax_Base.binder_ty = t2; Pulse_Syntax_Base.binder_ppname - = ppname + = ppname1 }, u, (Pulse_Syntax_Naming.close_st_term body1 x), @@ -1065,6 +1095,7 @@ let rec (check_abs : uu___7))) uu___7))) uu___7))) + uu___7))) uu___6))) uu___5))) uu___4))) diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Admit.ml b/src/ocaml/plugin/generated/Pulse_Checker_Admit.ml index 74797d0ab..bd7d5dda0 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Admit.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Admit.ml @@ -5,145 +5,288 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (28)) (Prims.of_int (43)) - (Prims.of_int (28)) (Prims.of_int (49))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (26)) (Prims.of_int (46)) - (Prims.of_int (68)) (Prims.of_int (55))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_Admit - { Pulse_Syntax_Base.ctag1 = c; - Pulse_Syntax_Base.u1 = uu___1; - Pulse_Syntax_Base.typ = t1; - Pulse_Syntax_Base.post3 = post;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (30)) (Prims.of_int (10)) - (Prims.of_int (30)) (Prims.of_int (17))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (30)) (Prims.of_int (20)) - (Prims.of_int (68)) (Prims.of_int (55))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> Pulse_Typing_Env.fresh g)) - (fun uu___2 -> - (fun x -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (31)) - (Prims.of_int (11)) - (Prims.of_int (31)) - (Prims.of_int (20))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (31)) - (Prims.of_int (23)) - (Prims.of_int (68)) - (Prims.of_int (55))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Syntax_Base.v_as_nv x)) - (fun uu___2 -> - (fun px -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (38)) - (Prims.of_int (6)) - (Prims.of_int (60)) - (Prims.of_int (9))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Admit.fst" - (Prims.of_int (61)) - (Prims.of_int (4)) - (Prims.of_int (68)) - (Prims.of_int (55))))) - (match (post, post_hint) - with - | (FStar_Pervasives_Native.None, - FStar_Pervasives_Native.None) - -> - Obj.magic - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "T_Admit: either no post or two posts") - | (FStar_Pervasives_Native.Some - uu___2, - FStar_Pervasives_Native.Some - uu___3) -> - Obj.magic - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "T_Admit: either no post or two posts") - | (FStar_Pervasives_Native.Some - post1, uu___2) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" + (Prims.of_int (31)) (Prims.of_int (10)) + (Prims.of_int (31)) (Prims.of_int (63))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" + (Prims.of_int (31)) (Prims.of_int (66)) + (Prims.of_int (78)) (Prims.of_int (75))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_admit" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (33)) (Prims.of_int (43)) + (Prims.of_int (33)) (Prims.of_int (49))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (31)) (Prims.of_int (66)) + (Prims.of_int (78)) (Prims.of_int (75))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_Admit + { Pulse_Syntax_Base.ctag1 = c; + Pulse_Syntax_Base.u1 = uu___1; + Pulse_Syntax_Base.typ = t1; + Pulse_Syntax_Base.post3 = post;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (35)) + (Prims.of_int (10)) + (Prims.of_int (35)) + (Prims.of_int (17))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (35)) + (Prims.of_int (20)) + (Prims.of_int (78)) + (Prims.of_int (75))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Pulse_Typing_Env.fresh g1)) + (fun uu___2 -> + (fun x -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (36)) + (Prims.of_int (11)) + (Prims.of_int (36)) + (Prims.of_int (20))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (36)) + (Prims.of_int (23)) + (Prims.of_int (78)) + (Prims.of_int (75))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Pulse_Syntax_Base.v_as_nv + x)) + (fun uu___2 -> + (fun px -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (43)) + (Prims.of_int (6)) + (Prims.of_int (70)) + (Prims.of_int (9))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (71)) + (Prims.of_int (4)) + (Prims.of_int (78)) + (Prims.of_int (75))))) + (match + (post, + post_hint) + with + | (FStar_Pervasives_Native.None, + FStar_Pervasives_Native.None) + -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + FStar_Pervasives_Native.None + "could not find a post annotation on admit, please add one") + | (FStar_Pervasives_Native.Some + post1, + FStar_Pervasives_Native.Some + post2) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (49)) + (Prims.of_int (10)) + (Prims.of_int (51)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (48)) + (Prims.of_int (8)) + (Prims.of_int (51)) + (Prims.of_int (43))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (51)) + (Prims.of_int (13)) + (Prims.of_int (51)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (49)) + (Prims.of_int (10)) + (Prims.of_int (51)) + (Prims.of_int (43))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + post2.Pulse_Typing.post)) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (49)) + (Prims.of_int (10)) + (Prims.of_int (51)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (49)) + (Prims.of_int (10)) + (Prims.of_int (51)) + (Prims.of_int (43))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Admit.fst" + (Prims.of_int (50)) + (Prims.of_int (13)) + (Prims.of_int (50)) + (Prims.of_int (37))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + post1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + fun x1 -> + Prims.strcat + (Prims.strcat + "found two post annotations on admit: " + (Prims.strcat + uu___3 + " and ")) + (Prims.strcat + x1 + ", please remove one"))))) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + uu___3 + uu___2)))) + uu___2))) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + FStar_Pervasives_Native.None + uu___2)) + uu___2)) + | (FStar_Pervasives_Native.Some + post1, + uu___2) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (44)) + (Prims.of_int (54)) (Prims.of_int (32)) - (Prims.of_int (44)) + (Prims.of_int (54)) (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (43)) + (Prims.of_int (53)) (Prims.of_int (23)) - (Prims.of_int (49)) + (Prims.of_int (59)) (Prims.of_int (49))))) - (Obj.magic - (Pulse_Checker_Pure.check_universe - g t1)) - (fun uu___3 -> - (fun uu___3 - -> - match uu___3 - with - | - Prims.Mkdtuple2 + (Obj.magic + (Pulse_Checker_Pure.check_universe + g1 t1)) + (fun + uu___3 -> + (fun + uu___3 -> + match uu___3 + with + | + Prims.Mkdtuple2 (u, t_typing) -> @@ -153,17 +296,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (45)) + (Prims.of_int (55)) (Prims.of_int (26)) - (Prims.of_int (45)) + (Prims.of_int (55)) (Prims.of_int (46))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (45)) - (Prims.of_int (49)) + (Prims.of_int (55)) (Prims.of_int (49)) + (Prims.of_int (59)) (Prims.of_int (49))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -181,22 +324,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (47)) + (Prims.of_int (57)) (Prims.of_int (12)) - (Prims.of_int (47)) + (Prims.of_int (57)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (45)) - (Prims.of_int (49)) + (Prims.of_int (55)) (Prims.of_int (49)) + (Prims.of_int (59)) (Prims.of_int (49))))) (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type (Pulse_Typing_Env.push_binding - g x + g1 x (FStar_Pervasives_Native.fst px) t1) post_opened @@ -219,46 +362,49 @@ let (check : post2, ()))))) uu___4))) - uu___3)) - | (uu___2, - FStar_Pervasives_Native.Some - post1) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + uu___3)) + | (uu___2, + FStar_Pervasives_Native.Some + post1) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (52)) + (Prims.of_int (62)) (Prims.of_int (33)) - (Prims.of_int (52)) + (Prims.of_int (62)) (Prims.of_int (37))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (53)) + (Prims.of_int (63)) (Prims.of_int (8)) - (Prims.of_int (60)) + (Prims.of_int (70)) (Prims.of_int (9))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___3 - -> post1)) - (fun uu___3 -> - (fun post2 -> - if + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + post1)) + (fun + uu___3 -> + (fun + post2 -> + if FStar_Set.mem x (Pulse_Syntax_Naming.freevars post2.Pulse_Typing.post) - then + then Obj.magic (Obj.repr (Pulse_Typing_Env.fail - g + g1 FStar_Pervasives_Native.None - "Unexpected freevar clash in Tm_Admit")) - else + "Impossible: unexpected freevar clash in Tm_Admit, please file a bug-report")) + else Obj.magic (Obj.repr (FStar_Tactics_Effect.lift_div_tac @@ -271,35 +417,37 @@ let (check : (Pulse_Syntax_Naming.open_term_nv post2.Pulse_Typing.post px), ()))))) - uu___3))) - (fun uu___2 -> - (fun res -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + uu___3))) + (fun uu___2 + -> + (fun res + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (62)) + (Prims.of_int (72)) (Prims.of_int (55)) - (Prims.of_int (62)) + (Prims.of_int (72)) (Prims.of_int (58))))) - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (61)) + (Prims.of_int (71)) (Prims.of_int (4)) - (Prims.of_int (68)) - (Prims.of_int (55))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 - -> res)) - (fun uu___2 -> - (fun uu___2 - -> + (Prims.of_int (78)) + (Prims.of_int (75))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + res)) + (fun + uu___2 -> + (fun + uu___2 -> match uu___2 with | @@ -315,18 +463,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (63)) + (Prims.of_int (73)) (Prims.of_int (13)) - (Prims.of_int (63)) + (Prims.of_int (73)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (63)) + (Prims.of_int (73)) (Prims.of_int (40)) - (Prims.of_int (68)) - (Prims.of_int (55))))) + (Prims.of_int (78)) + (Prims.of_int (75))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -343,18 +491,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (64)) + (Prims.of_int (74)) (Prims.of_int (21)) - (Prims.of_int (64)) + (Prims.of_int (74)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (66)) + (Prims.of_int (76)) (Prims.of_int (65)) - (Prims.of_int (68)) - (Prims.of_int (55))))) + (Prims.of_int (78)) + (Prims.of_int (75))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -377,27 +525,28 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (67)) + (Prims.of_int (77)) (Prims.of_int (10)) - (Prims.of_int (67)) + (Prims.of_int (77)) (Prims.of_int (67))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (68)) + (Prims.of_int (78)) (Prims.of_int (2)) - (Prims.of_int (68)) - (Prims.of_int (55))))) + (Prims.of_int (78)) + (Prims.of_int (75))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> Pulse_Typing.T_Admit - (g, s, c, + (g1, s, + c, (Pulse_Typing.STC - (g, s, x, - (), (), - ()))))) + (g1, s, + x, (), + (), ()))))) (fun uu___3 -> (fun d -> @@ -407,18 +556,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (68)) - (Prims.of_int (9)) - (Prims.of_int (68)) - (Prims.of_int (37))))) + (Prims.of_int (78)) + (Prims.of_int (18)) + (Prims.of_int (78)) + (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Admit.fst" - (Prims.of_int (68)) + (Prims.of_int (78)) (Prims.of_int (2)) - (Prims.of_int (68)) - (Prims.of_int (55))))) + (Prims.of_int (78)) + (Prims.of_int (75))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -438,13 +587,14 @@ let (check : FStar_Pervasives_Native.None })) (Pulse_Typing.comp_admit - c s) d)) + c s) d + res_ppname)) (fun uu___3 -> (fun uu___3 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___3 post_hint @@ -453,6 +603,7 @@ let (check : uu___3))) uu___3))) uu___3))) - uu___2))) - uu___2))) uu___2))) - uu___2))) uu___) \ No newline at end of file + uu___2))) + uu___2))) + uu___2))) uu___2))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_AssertWithBinders.ml b/src/ocaml/plugin/generated/Pulse_Checker_AssertWithBinders.ml index 1cf868c87..3b0fd6640 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_AssertWithBinders.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_AssertWithBinders.ml @@ -49,7 +49,7 @@ let rec (refl_abs_binders : (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" (Prims.of_int (33)) (Prims.of_int (20)) - (Prims.of_int (37)) (Prims.of_int (87))))) + (Prims.of_int (39)) (Prims.of_int (87))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> FStar_Reflection_V2_Builtins.inspect_binder b)) @@ -69,20 +69,70 @@ let rec (refl_abs_binders : "Pulse.Checker.AssertWithBinders.fst" (Prims.of_int (35)) (Prims.of_int (15)) - (Prims.of_int (35)) - (Prims.of_int (96))))) + (Prims.of_int (37)) + (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (36)) + (Prims.of_int (38)) (Prims.of_int (4)) - (Prims.of_int (37)) + (Prims.of_int (39)) (Prims.of_int (87))))) (Obj.magic - (option_must - (Pulse_Readback.readback_ty sort) - "Failed to readback elaborated binder in peel_off")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (36)) + (Prims.of_int (6)) + (Prims.of_int (37)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (35)) + (Prims.of_int (15)) + (Prims.of_int (37)) + (Prims.of_int (33))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (37)) + (Prims.of_int (9)) + (Prims.of_int (37)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_V2_Builtins.term_to_string + sort)) + (fun uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___4 -> + Prims.strcat + "Failed to readback elaborated binder sort " + (Prims.strcat + uu___3 + " in refl_abs_binders"))))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (option_must + (Pulse_Readback.readback_ty + sort) uu___3)) + uu___3))) (fun uu___3 -> (fun sort1 -> Obj.magic @@ -129,14 +179,14 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (45)) (Prims.of_int (13)) - (Prims.of_int (45)) (Prims.of_int (24))))) + (Prims.of_int (47)) (Prims.of_int (13)) + (Prims.of_int (47)) (Prims.of_int (24))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (46)) (Prims.of_int (4)) - (Prims.of_int (68)) (Prims.of_int (80))))) + (Prims.of_int (48)) (Prims.of_int (4)) + (Prims.of_int (72)) (Prims.of_int (106))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Elaborate_Pure.elab_term v)) (fun uu___1 -> @@ -147,18 +197,18 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (46)) + (Prims.of_int (48)) (Prims.of_int (4)) - (Prims.of_int (47)) - (Prims.of_int (94))))) + (Prims.of_int (51)) + (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (47)) - (Prims.of_int (95)) - (Prims.of_int (68)) - (Prims.of_int (80))))) + (Prims.of_int (51)) + (Prims.of_int (58)) + (Prims.of_int (72)) + (Prims.of_int (106))))) (if Prims.op_Negation (is_host_term tv) then Obj.magic @@ -168,46 +218,103 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (47)) - (Prims.of_int (31)) - (Prims.of_int (47)) - (Prims.of_int (94))))) + (Prims.of_int (50)) + (Prims.of_int (11)) + (Prims.of_int (51)) + (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (47)) + (Prims.of_int (49)) (Prims.of_int (9)) - (Prims.of_int (47)) - (Prims.of_int (94))))) + (Prims.of_int (51)) + (Prims.of_int (57))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (47)) - (Prims.of_int (73)) - (Prims.of_int (47)) - (Prims.of_int (93))))) + (Prims.of_int (51)) + (Prims.of_int (35)) + (Prims.of_int (51)) + (Prims.of_int (56))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range - "prims.fst" - (Prims.of_int (590)) - (Prims.of_int (19)) - (Prims.of_int (590)) - (Prims.of_int (31))))) + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (50)) + (Prims.of_int (11)) + (Prims.of_int (51)) + (Prims.of_int (57))))) (Obj.magic - (Pulse_Syntax_Printer.term_to_string - v)) + (FStar_Tactics_V2_Builtins.term_to_string + tv)) (fun uu___1 -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Prims.strcat - "Cannot infer type of " - (Prims.strcat - uu___1 ""))))) + (fun uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (50)) + (Prims.of_int (11)) + (Prims.of_int (51)) + (Prims.of_int (57))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (50)) + (Prims.of_int (11)) + (Prims.of_int (51)) + (Prims.of_int (57))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (51)) + (Prims.of_int (14)) + (Prims.of_int (51)) + (Prims.of_int (34))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + v)) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + fun x -> + Prims.strcat + (Prims.strcat + "assert.infer_binder_types: elaborated " + (Prims.strcat + uu___2 + " to ")) + (Prims.strcat + x + ", which failed the host term check"))))) + (fun uu___2 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + uu___2 + uu___1)))) + uu___1))) (fun uu___1 -> (fun uu___1 -> Obj.magic @@ -229,18 +336,18 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (49)) + (Prims.of_int (53)) (Prims.of_int (6)) - (Prims.of_int (55)) + (Prims.of_int (59)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (56)) + (Prims.of_int (60)) (Prims.of_int (6)) - (Prims.of_int (68)) - (Prims.of_int (80))))) + (Prims.of_int (72)) + (Prims.of_int (106))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> fun b -> @@ -267,18 +374,18 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (58)) + (Prims.of_int (62)) (Prims.of_int (6)) - (Prims.of_int (63)) + (Prims.of_int (67)) (Prims.of_int (10))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (64)) - (Prims.of_int (6)) (Prims.of_int (68)) - (Prims.of_int (80))))) + (Prims.of_int (6)) + (Prims.of_int (72)) + (Prims.of_int (106))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> FStar_List_Tot_Base.fold_right @@ -302,18 +409,18 @@ let (infer_binder_types : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (65)) + (Prims.of_int (69)) (Prims.of_int (30)) - (Prims.of_int (65)) + (Prims.of_int (69)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (64)) - (Prims.of_int (6)) (Prims.of_int (68)) - (Prims.of_int (80))))) + (Prims.of_int (6)) + (Prims.of_int (72)) + (Prims.of_int (106))))) (Obj.magic (Pulse_Checker_Pure.instantiate_term_implicits g @@ -345,7 +452,7 @@ let (infer_binder_types : Obj.magic (Obj.repr (FStar_Tactics_V2_Derived.fail - "Impossible: Instantiated abstraction is not embedded F* term")))) + "Impossible: instantiated abstraction is not embedded F* term, please file a bug-report")))) uu___2))) uu___2))) uu___2))) uu___1))) @@ -386,17 +493,17 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (77)) + (Prims.of_int (81)) (Prims.of_int (12)) - (Prims.of_int (77)) + (Prims.of_int (81)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (77)) + (Prims.of_int (81)) (Prims.of_int (61)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) (Obj.magic (Pulse_Checker_Pure.check_universe @@ -410,17 +517,17 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (78)) + (Prims.of_int (82)) (Prims.of_int (12)) - (Prims.of_int (78)) + (Prims.of_int (82)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (78)) + (Prims.of_int (82)) (Prims.of_int (37)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -435,17 +542,17 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (79)) + (Prims.of_int (83)) (Prims.of_int (13)) - (Prims.of_int (79)) + (Prims.of_int (83)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (79)) + (Prims.of_int (83)) (Prims.of_int (72)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -469,18 +576,18 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (80)) + (Prims.of_int (84)) (Prims.of_int (13)) - (Prims.of_int (82)) + (Prims.of_int (86)) (Prims.of_int (45))))) ( FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (82)) + (Prims.of_int (86)) (Prims.of_int (48)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) ( FStar_Tactics_Effect.lift_div_tac @@ -505,17 +612,17 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (83)) + (Prims.of_int (87)) (Prims.of_int (12)) - (Prims.of_int (83)) + (Prims.of_int (87)) (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (83)) + (Prims.of_int (87)) (Prims.of_int (60)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -535,17 +642,17 @@ let rec (open_binders : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (84)) + (Prims.of_int (88)) (Prims.of_int (15)) - (Prims.of_int (84)) + (Prims.of_int (88)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (4)) - (Prims.of_int (85)) + (Prims.of_int (89)) (Prims.of_int (77))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -604,13 +711,13 @@ let (unfold_defs : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (97)) (Prims.of_int (12)) - (Prims.of_int (97)) (Prims.of_int (23))))) + (Prims.of_int (101)) (Prims.of_int (12)) + (Prims.of_int (101)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (97)) (Prims.of_int (26)) - (Prims.of_int (115)) (Prims.of_int (97))))) + (Prims.of_int (101)) (Prims.of_int (26)) + (Prims.of_int (122)) (Prims.of_int (89))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_Elaborate_Pure.elab_term t)) (fun uu___ -> @@ -621,14 +728,14 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (98)) (Prims.of_int (18)) - (Prims.of_int (98)) (Prims.of_int (33))))) + (Prims.of_int (102)) (Prims.of_int (18)) + (Prims.of_int (102)) (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (97)) (Prims.of_int (26)) - (Prims.of_int (115)) (Prims.of_int (97))))) + (Prims.of_int (101)) (Prims.of_int (26)) + (Prims.of_int (122)) (Prims.of_int (89))))) (Obj.magic (FStar_Tactics_V2_SyntaxHelpers.collect_app t1)) (fun uu___ -> @@ -645,17 +752,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (19)) - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (57)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -670,17 +777,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (104)) + (Prims.of_int (108)) (Prims.of_int (10)) - (Prims.of_int (106)) + (Prims.of_int (110)) (Prims.of_int (22))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (107)) + (Prims.of_int (111)) (Prims.of_int (10)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -697,17 +804,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (108)) + (Prims.of_int (112)) (Prims.of_int (17)) - (Prims.of_int (108)) + (Prims.of_int (112)) (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (108)) - (Prims.of_int (60)) (Prims.of_int (112)) + (Prims.of_int (60)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 @@ -724,22 +831,75 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (109)) + (Prims.of_int (113)) (Prims.of_int (17)) - (Prims.of_int (109)) - (Prims.of_int (83))))) + (Prims.of_int (114)) + (Prims.of_int (76))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (109)) - (Prims.of_int (86)) - (Prims.of_int (112)) + (Prims.of_int (114)) + (Prims.of_int (79)) + (Prims.of_int (118)) (Prims.of_int (10))))) (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (114)) + (Prims.of_int (10)) + (Prims.of_int (114)) + (Prims.of_int (76))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (113)) + (Prims.of_int (17)) + (Prims.of_int (114)) + (Prims.of_int (76))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (114)) + (Prims.of_int (55)) + (Prims.of_int (114)) + (Prims.of_int (75))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_V2_Builtins.term_to_string + t1)) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Prims.strcat + "unfolding " + (Prims.strcat + uu___2 + " returned None"))))) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic (option_must - rt - "Unexpected: reduction produced an ill-formed term")) + rt uu___2)) + uu___2))) (fun uu___2 -> (fun rt1 @@ -750,23 +910,76 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (17)) - (Prims.of_int (110)) - (Prims.of_int (92))))) + (Prims.of_int (116)) + (Prims.of_int (93))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (8)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (116)) + (Prims.of_int (10)) + (Prims.of_int (116)) + (Prims.of_int (93))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (115)) + (Prims.of_int (17)) + (Prims.of_int (116)) + (Prims.of_int (93))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (116)) + (Prims.of_int (71)) + (Prims.of_int (116)) + (Prims.of_int (92))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_V2_Builtins.term_to_string + rt1)) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Prims.strcat + "error in reading back the unfolded term " + (Prims.strcat + uu___2 ""))))) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic (option_must (Pulse_Readback.readback_ty rt1) - "Unexpected: unable to readback unfolded term")) + uu___2)) + uu___2))) (fun uu___2 -> (fun ty @@ -777,17 +990,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (8)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (157))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (12)) - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (14))))) (Obj.magic (debug_log @@ -799,17 +1012,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (135)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -824,17 +1037,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -842,17 +1055,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (113)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (134))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_V2_Builtins.term_to_string @@ -867,17 +1080,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -885,9 +1098,9 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (92)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (112))))) (FStar_Sealed.seal (Obj.magic @@ -953,17 +1166,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (19)) - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (102)) + (Prims.of_int (106)) (Prims.of_int (57)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -978,17 +1191,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (104)) + (Prims.of_int (108)) (Prims.of_int (10)) - (Prims.of_int (106)) + (Prims.of_int (110)) (Prims.of_int (22))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (107)) + (Prims.of_int (111)) (Prims.of_int (10)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -1005,17 +1218,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (108)) + (Prims.of_int (112)) (Prims.of_int (17)) - (Prims.of_int (108)) + (Prims.of_int (112)) (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (108)) - (Prims.of_int (60)) (Prims.of_int (112)) + (Prims.of_int (60)) + (Prims.of_int (118)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 @@ -1032,22 +1245,75 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (109)) + (Prims.of_int (113)) (Prims.of_int (17)) - (Prims.of_int (109)) - (Prims.of_int (83))))) + (Prims.of_int (114)) + (Prims.of_int (76))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (109)) - (Prims.of_int (86)) - (Prims.of_int (112)) + (Prims.of_int (114)) + (Prims.of_int (79)) + (Prims.of_int (118)) (Prims.of_int (10))))) (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (114)) + (Prims.of_int (10)) + (Prims.of_int (114)) + (Prims.of_int (76))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (113)) + (Prims.of_int (17)) + (Prims.of_int (114)) + (Prims.of_int (76))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (114)) + (Prims.of_int (55)) + (Prims.of_int (114)) + (Prims.of_int (75))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_V2_Builtins.term_to_string + t1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Prims.strcat + "unfolding " + (Prims.strcat + uu___3 + " returned None"))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic (option_must - rt - "Unexpected: reduction produced an ill-formed term")) + rt uu___3)) + uu___3))) (fun uu___3 -> (fun rt1 @@ -1058,23 +1324,76 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (17)) - (Prims.of_int (110)) - (Prims.of_int (92))))) + (Prims.of_int (116)) + (Prims.of_int (93))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (8)) - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (10))))) (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (116)) + (Prims.of_int (10)) + (Prims.of_int (116)) + (Prims.of_int (93))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (115)) + (Prims.of_int (17)) + (Prims.of_int (116)) + (Prims.of_int (93))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (116)) + (Prims.of_int (71)) + (Prims.of_int (116)) + (Prims.of_int (92))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_V2_Builtins.term_to_string + rt1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Prims.strcat + "error in reading back the unfolded term " + (Prims.strcat + uu___3 ""))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic (option_must (Pulse_Readback.readback_ty rt1) - "Unexpected: unable to readback unfolded term")) + uu___3)) + uu___3))) (fun uu___3 -> (fun ty @@ -1085,17 +1404,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (8)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (157))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (12)) - (Prims.of_int (110)) + (Prims.of_int (115)) (Prims.of_int (14))))) (Obj.magic (debug_log @@ -1107,17 +1426,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (135)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1132,17 +1451,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1150,17 +1469,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (113)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (134))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_V2_Builtins.term_to_string @@ -1175,17 +1494,17 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (30)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (156))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1193,9 +1512,9 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (92)) - (Prims.of_int (111)) + (Prims.of_int (117)) (Prims.of_int (112))))) (FStar_Sealed.seal (Obj.magic @@ -1260,28 +1579,28 @@ let (unfold_defs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (115)) - (Prims.of_int (41)) - (Prims.of_int (115)) - (Prims.of_int (97))))) + (Prims.of_int (122)) + (Prims.of_int (8)) + (Prims.of_int (122)) + (Prims.of_int (89))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (115)) + (Prims.of_int (121)) (Prims.of_int (6)) - (Prims.of_int (115)) - (Prims.of_int (97))))) + (Prims.of_int (122)) + (Prims.of_int (89))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (115)) - (Prims.of_int (76)) - (Prims.of_int (115)) - (Prims.of_int (96))))) + (Prims.of_int (122)) + (Prims.of_int (68)) + (Prims.of_int (122)) + (Prims.of_int (88))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range @@ -1299,7 +1618,7 @@ let (unfold_defs : Prims.strcat "Cannot unfold " (Prims.strcat uu___3 - ""))))) + ", the head is not an fvar"))))) (fun uu___3 -> (fun uu___3 -> Obj.magic @@ -1329,23 +1648,23 @@ let (check_unfoldable : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (123)) (Prims.of_int (6)) - (Prims.of_int (125)) (Prims.of_int (45))))) + (Prims.of_int (130)) (Prims.of_int (6)) + (Prims.of_int (132)) (Prims.of_int (45))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (121)) (Prims.of_int (3)) - (Prims.of_int (125)) (Prims.of_int (45))))) + (Prims.of_int (128)) (Prims.of_int (3)) + (Prims.of_int (132)) (Prims.of_int (45))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (125)) + (Prims.of_int (132)) (Prims.of_int (24)) - (Prims.of_int (125)) + (Prims.of_int (132)) (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic @@ -1375,123 +1694,156 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun st -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (137)) (Prims.of_int (69)) - (Prims.of_int (137)) (Prims.of_int (76))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (135)) (Prims.of_int (46)) - (Prims.of_int (181)) (Prims.of_int (39))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> st.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_ProofHintWithBinders - { Pulse_Syntax_Base.hint_type = hint_type; - Pulse_Syntax_Base.binders = bs; - Pulse_Syntax_Base.v = v; - Pulse_Syntax_Base.t3 = body;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (139)) - (Prims.of_int (11)) - (Prims.of_int (139)) - (Prims.of_int (36))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (139)) - (Prims.of_int (39)) - (Prims.of_int (181)) - (Prims.of_int (39))))) - (Obj.magic (infer_binder_types g bs v)) - (fun uu___1 -> - (fun bs1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (141)) - (Prims.of_int (41)) - (Prims.of_int (141)) - (Prims.of_int (88))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (139)) - (Prims.of_int (39)) - (Prims.of_int (181)) - (Prims.of_int (39))))) - (Obj.magic - (open_binders g bs1 - (Pulse_Typing_Env.mk_env - (Pulse_Typing_Env.fstar_env - g)) v body)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | FStar_Pervasives.Mkdtuple3 - (uvs, v_opened, - body_opened) - -> - (match hint_type with - | Pulse_Syntax_Base.ASSERT - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + fun res_ppname -> + fun st -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (145)) (Prims.of_int (10)) + (Prims.of_int (145)) (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (145)) (Prims.of_int (51)) + (Prims.of_int (191)) (Prims.of_int (50))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_assert" + st.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (147)) + (Prims.of_int (69)) + (Prims.of_int (147)) + (Prims.of_int (76))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (145)) + (Prims.of_int (51)) + (Prims.of_int (191)) + (Prims.of_int (50))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> st.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_ProofHintWithBinders + { + Pulse_Syntax_Base.hint_type = + hint_type; + Pulse_Syntax_Base.binders = bs; + Pulse_Syntax_Base.v = v; + Pulse_Syntax_Base.t3 = body;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (149)) + (Prims.of_int (11)) + (Prims.of_int (149)) + (Prims.of_int (36))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (149)) + (Prims.of_int (39)) + (Prims.of_int (191)) + (Prims.of_int (50))))) + (Obj.magic + (infer_binder_types g1 bs v)) + (fun uu___1 -> + (fun bs1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (151)) + (Prims.of_int (41)) + (Prims.of_int (151)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.AssertWithBinders.fst" + (Prims.of_int (149)) + (Prims.of_int (39)) + (Prims.of_int (191)) + (Prims.of_int (50))))) + (Obj.magic + (open_binders g1 + bs1 + (Pulse_Typing_Env.mk_env + (Pulse_Typing_Env.fstar_env + g1)) v + body)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 + with + | FStar_Pervasives.Mkdtuple3 + (uvs, + v_opened, + body_opened) + -> + (match hint_type + with + | Pulse_Syntax_Base.ASSERT + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (145)) + (Prims.of_int (155)) (Prims.of_int (18)) - (Prims.of_int (145)) + (Prims.of_int (155)) (Prims.of_int (39))))) - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (144)) + (Prims.of_int (154)) (Prims.of_int (13)) - (Prims.of_int (150)) + (Prims.of_int (160)) (Prims.of_int (52))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 - -> + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> (v_opened, body_opened))) - (fun uu___2 -> - (fun uu___2 - -> + (fun + uu___2 -> + (fun + uu___2 -> match uu___2 with | @@ -1503,22 +1855,23 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (146)) + (Prims.of_int (156)) (Prims.of_int (21)) - (Prims.of_int (146)) + (Prims.of_int (156)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (145)) + (Prims.of_int (155)) (Prims.of_int (42)) - (Prims.of_int (150)) + (Prims.of_int (160)) (Prims.of_int (52))))) (Obj.magic (Pulse_Checker_Pure.check_vprop (Pulse_Typing_Env.push_env - g uvs) v1)) + g1 uvs) + v1)) (fun uu___3 -> (fun @@ -1535,17 +1888,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (147)) + (Prims.of_int (157)) (Prims.of_int (39)) - (Prims.of_int (147)) + (Prims.of_int (157)) (Prims.of_int (68))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (146)) + (Prims.of_int (156)) (Prims.of_int (57)) - (Prims.of_int (150)) + (Prims.of_int (160)) (Prims.of_int (52))))) (Obj.magic (Pulse_Checker_Prover.prove @@ -1559,7 +1912,8 @@ let (check : with | FStar_Pervasives.Mkdtuple4 - (g1, nts, + (g11, + nts, pre', k_frame) -> @@ -1569,26 +1923,27 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (149)) + (Prims.of_int (159)) (Prims.of_int (6)) - (Prims.of_int (149)) - (Prims.of_int (106))))) + (Prims.of_int (159)) + (Prims.of_int (117))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (147)) + (Prims.of_int (157)) (Prims.of_int (71)) - (Prims.of_int (150)) + (Prims.of_int (160)) (Prims.of_int (52))))) (Obj.magic (check1 - g1 + g11 (Pulse_Syntax_Base.tm_star (Pulse_Checker_Prover_Substs.nt_subst_term v2 nts) pre') () post_hint + res_ppname (Pulse_Checker_Prover_Substs.nt_subst_st_term body1 nts))) (fun @@ -1608,66 +1963,66 @@ let (check : pre'', g2, (Pulse_Checker_Base.k_elab_trans - g g1 g2 - pre + g g11 + x_ty pre (Pulse_Checker_Prover_Base.op_Star (Pulse_Checker_Prover_Substs.nt_subst_term v2 nts) pre') - pre'' + (FStar_Pervasives.dfst + g2) k_frame k)))))) uu___4))) uu___3))) - uu___2)) - | uu___2 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + uu___2)) + | uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (153)) + (Prims.of_int (163)) (Prims.of_int (4)) - (Prims.of_int (153)) + (Prims.of_int (163)) (Prims.of_int (24))))) - (FStar_Sealed.seal - (Obj.magic - ( - FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (153)) + (Prims.of_int (163)) (Prims.of_int (25)) - (Prims.of_int (181)) - (Prims.of_int (39))))) - (Obj.magic - (check_unfoldable - g v)) - (fun uu___3 -> - (fun uu___3 - -> + (Prims.of_int (191)) + (Prims.of_int (50))))) + (Obj.magic + (check_unfoldable + g1 v)) + (fun + uu___3 -> + (fun + uu___3 -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (154)) + (Prims.of_int (164)) (Prims.of_int (22)) - (Prims.of_int (154)) + (Prims.of_int (164)) (Prims.of_int (77))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (153)) + (Prims.of_int (163)) (Prims.of_int (25)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (Obj.magic (Pulse_Checker_Pure.instantiate_term_implicits (Pulse_Typing_Env.push_env - g uvs) + g1 uvs) v_opened)) (fun uu___4 -> @@ -1685,18 +2040,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (156)) + (Prims.of_int (166)) (Prims.of_int (6)) - (Prims.of_int (162)) + (Prims.of_int (172)) (Prims.of_int (16))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (154)) + (Prims.of_int (164)) (Prims.of_int (80)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (match hint_type with | @@ -1708,22 +2063,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (159)) + (Prims.of_int (169)) (Prims.of_int (8)) - (Prims.of_int (159)) + (Prims.of_int (169)) (Prims.of_int (50))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (158)) + (Prims.of_int (168)) (Prims.of_int (8)) - (Prims.of_int (159)) + (Prims.of_int (169)) (Prims.of_int (50))))) (Obj.magic (unfold_defs (Pulse_Typing_Env.push_env - g uvs) + g1 uvs) FStar_Pervasives_Native.None v_opened1)) (fun @@ -1742,22 +2097,23 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (161)) + (Prims.of_int (171)) (Prims.of_int (8)) - (Prims.of_int (161)) + (Prims.of_int (171)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (161)) + (Prims.of_int (171)) (Prims.of_int (8)) - (Prims.of_int (162)) + (Prims.of_int (172)) (Prims.of_int (16))))) (Obj.magic (unfold_defs (Pulse_Typing_Env.push_env - g uvs) ns + g1 uvs) + ns v_opened1)) (fun uu___6 -> @@ -1781,18 +2137,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (163)) + (Prims.of_int (173)) (Prims.of_int (17)) - (Prims.of_int (163)) + (Prims.of_int (173)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (163)) + (Prims.of_int (173)) (Prims.of_int (40)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1809,18 +2165,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (164)) + (Prims.of_int (174)) (Prims.of_int (19)) - (Prims.of_int (164)) + (Prims.of_int (174)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (163)) + (Prims.of_int (173)) (Prims.of_int (40)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1845,18 +2201,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (165)) + (Prims.of_int (175)) (Prims.of_int (15)) - (Prims.of_int (167)) + (Prims.of_int (177)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (167)) + (Prims.of_int (177)) (Prims.of_int (36)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> @@ -1884,18 +2240,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (168)) + (Prims.of_int (178)) (Prims.of_int (15)) - (Prims.of_int (170)) + (Prims.of_int (180)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (170)) + (Prims.of_int (180)) (Prims.of_int (36)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> @@ -1933,18 +2289,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (173)) + (Prims.of_int (183)) (Prims.of_int (6)) - (Prims.of_int (180)) + (Prims.of_int (190)) (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.AssertWithBinders.fst" - (Prims.of_int (181)) + (Prims.of_int (191)) (Prims.of_int (4)) - (Prims.of_int (181)) - (Prims.of_int (39))))) + (Prims.of_int (191)) + (Prims.of_int (50))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> @@ -1978,9 +2334,10 @@ let (check : (fun st2 -> Obj.magic - (check1 g - pre () + (check1 + g1 pre () post_hint + res_ppname st2)) uu___8))) uu___8))) @@ -1989,5 +2346,6 @@ let (check : uu___7))) uu___6))) uu___4))) - uu___3)))) - uu___1))) uu___1))) uu___) \ No newline at end of file + uu___3)))) + uu___1))) uu___1))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Base.ml b/src/ocaml/plugin/generated/Pulse_Checker_Base.ml index 64b952ced..69fd2fd1a 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Base.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Base.ml @@ -456,16 +456,16 @@ let (intro_post_hint : let (post_hint_from_comp_typing : Pulse_Typing_Env.env -> Pulse_Syntax_Base.comp_st -> - (unit, unit) Pulse_Typing_Metatheory.comp_typing_u -> + (unit, unit) Pulse_Typing_Metatheory_Base.comp_typing_u -> unit Pulse_Typing.post_hint_for_env) = fun g -> fun c -> fun ct -> let st_comp_typing = - Pulse_Typing_Metatheory.comp_typing_inversion g c ct in + Pulse_Typing_Metatheory_Base.comp_typing_inversion g c ct in let uu___ = - Pulse_Typing_Metatheory.st_comp_typing_inversion g + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion g (Pulse_Syntax_Base.st_comp_of_comp c) st_comp_typing in match uu___ with | FStar_Pervasives.Mkdtuple4 (ty_typing, pre_typing, x, post_typing) @@ -586,10 +586,11 @@ let (st_equiv_post : fun veq -> let c' = comp_st_with_post c post in let uu___ = - Pulse_Typing_Metatheory.st_comp_typing_inversion g + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion g (Pulse_Syntax_Base.st_comp_of_comp c) - (Pulse_Typing_Metatheory.comp_typing_inversion g c - (Pulse_Typing_Metatheory.st_typing_correctness g t c d)) in + (Pulse_Typing_Metatheory_Base.comp_typing_inversion g c + (Pulse_Typing_Metatheory_Base.st_typing_correctness g t + c d)) in match uu___ with | FStar_Pervasives.Mkdtuple4 (u_of, pre_typing, x, post_typing) -> @@ -635,7 +636,7 @@ let (k_elab_equiv_continutation : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" (Prims.of_int (138)) (Prims.of_int (4)) - (Prims.of_int (148)) (Prims.of_int (34))))) + (Prims.of_int (146)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> FStar_Pervasives.Mkdtuple3 @@ -658,8 +659,8 @@ let (k_elab_equiv_continutation : "Pulse.Checker.Base.fst" (Prims.of_int (138)) (Prims.of_int (4)) - (Prims.of_int (148)) - (Prims.of_int (34))))) + (Prims.of_int (146)) + (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> res)) (fun uu___ -> @@ -667,86 +668,72 @@ let (k_elab_equiv_continutation : match uu___ with | FStar_Pervasives.Mkdtuple3 (st, c, st_d) -> - if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c) - then - Obj.magic - (k post_hint - (FStar_Pervasives.Mkdtuple3 - (st, c, st_d))) - else - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (143)) - (Prims.of_int (18)) - (Prims.of_int (143)) - (Prims.of_int (95))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (141)) - (Prims.of_int (6)) - (Prims.of_int (148)) - (Prims.of_int (34))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing_Metatheory.st_comp_typing_inversion - g2 - (Pulse_Syntax_Base.st_comp_of_comp - c) - (Pulse_Typing_Metatheory.comp_typing_inversion - g2 c - (Pulse_Typing_Metatheory.st_typing_correctness - g2 st c st_d)))) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | FStar_Pervasives.Mkdtuple4 - (uu___3, - pre_typing, - uu___4, uu___5) - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - ( - Obj.magic + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (141)) + (Prims.of_int (16)) + (Prims.of_int (141)) + (Prims.of_int (93))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (139)) + (Prims.of_int (32)) + (Prims.of_int (146)) + (Prims.of_int (32))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion + g2 + (Pulse_Syntax_Base.st_comp_of_comp + c) + (Pulse_Typing_Metatheory_Base.comp_typing_inversion + g2 c + (Pulse_Typing_Metatheory_Base.st_typing_correctness + g2 st c st_d)))) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | FStar_Pervasives.Mkdtuple4 + (uu___2, + pre_typing, + uu___3, uu___4) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (145)) - (Prims.of_int (6)) - (Prims.of_int (145)) - (Prims.of_int (73))))) - (FStar_Sealed.seal - ( - Obj.magic + (Prims.of_int (143)) + (Prims.of_int (4)) + (Prims.of_int (143)) + (Prims.of_int (71))))) + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (143)) - (Prims.of_int (99)) - (Prims.of_int (148)) - (Prims.of_int (34))))) - (FStar_Tactics_Effect.lift_div_tac - ( - fun - uu___6 -> + (Prims.of_int (141)) + (Prims.of_int (97)) + (Prims.of_int (146)) + (Prims.of_int (32))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___5 + -> Pulse_Typing_Combinators.apply_frame g2 st ctxt1 () c st_d framing_token)) - (fun uu___6 + (fun uu___5 -> + (fun uu___5 -> - (fun - uu___6 -> - match uu___6 + match uu___5 with | Prims.Mkdtuple2 @@ -758,28 +745,28 @@ let (k_elab_equiv_continutation : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (147)) - (Prims.of_int (16)) - (Prims.of_int (147)) - (Prims.of_int (49))))) + (Prims.of_int (145)) + (Prims.of_int (14)) + (Prims.of_int (145)) + (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (148)) - (Prims.of_int (4)) - (Prims.of_int (148)) - (Prims.of_int (34))))) + (Prims.of_int (146)) + (Prims.of_int (2)) + (Prims.of_int (146)) + (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun - uu___7 -> + uu___6 -> simplify_post g2 st c' st_d' (Pulse_Syntax_Base.comp_post c))) (fun - uu___7 -> + uu___6 -> (fun st_d'1 -> Obj.magic @@ -792,10 +779,9 @@ let (k_elab_equiv_continutation : (Pulse_Syntax_Base.comp_post c)), st_d'1)))) - uu___7))) uu___6))) - uu___2))) uu___))) - uu___) + uu___5))) + uu___1))) uu___))) uu___) let (k_elab_equiv_prefix : Pulse_Typing_Env.env -> @@ -819,13 +805,13 @@ let (k_elab_equiv_prefix : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (164)) (Prims.of_int (60)) - (Prims.of_int (166)) (Prims.of_int (31))))) + (Prims.of_int (162)) (Prims.of_int (60)) + (Prims.of_int (164)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (167)) (Prims.of_int (4)) - (Prims.of_int (182)) (Prims.of_int (11))))) + (Prims.of_int (165)) (Prims.of_int (4)) + (Prims.of_int (179)) (Prims.of_int (5))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> FStar_Pervasives.Mkdtuple3 @@ -838,18 +824,18 @@ let (k_elab_equiv_prefix : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (168)) + (Prims.of_int (166)) (Prims.of_int (12)) - (Prims.of_int (168)) + (Prims.of_int (166)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (168)) + (Prims.of_int (166)) (Prims.of_int (30)) - (Prims.of_int (182)) - (Prims.of_int (11))))) + (Prims.of_int (179)) + (Prims.of_int (5))))) (Obj.magic (k post_hint res)) (fun res1 -> FStar_Tactics_Effect.lift_div_tac @@ -857,45 +843,35 @@ let (k_elab_equiv_prefix : match res1 with | FStar_Pervasives.Mkdtuple3 (st, c, st_d) -> - if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c) - then - FStar_Pervasives.Mkdtuple3 - (st, c, st_d) - else - (match Pulse_Typing_Metatheory.st_comp_typing_inversion - g1 - (Pulse_Syntax_Base.st_comp_of_comp - c) - (Pulse_Typing_Metatheory.comp_typing_inversion - g1 c - (Pulse_Typing_Metatheory.st_typing_correctness - g1 st c st_d)) - with - | FStar_Pervasives.Mkdtuple4 - (uu___2, pre_typing, - uu___3, uu___4) - -> - (match Pulse_Typing_Combinators.apply_frame - g1 st ctxt2 () c - st_d - framing_token - with - | Prims.Mkdtuple2 - (c', st_d') -> - FStar_Pervasives.Mkdtuple3 - (st, - (comp_st_with_post - c' - (Pulse_Syntax_Base.comp_post - c)), - (simplify_post - g1 st c' - st_d' - (Pulse_Syntax_Base.comp_post - c))))))))) + (match Pulse_Typing_Metatheory_Base.st_comp_typing_inversion + g1 + (Pulse_Syntax_Base.st_comp_of_comp + c) + (Pulse_Typing_Metatheory_Base.comp_typing_inversion + g1 c + (Pulse_Typing_Metatheory_Base.st_typing_correctness + g1 st c st_d)) + with + | FStar_Pervasives.Mkdtuple4 + (uu___1, pre_typing, + uu___2, uu___3) + -> + (match Pulse_Typing_Combinators.apply_frame + g1 st ctxt2 () c + st_d framing_token + with + | Prims.Mkdtuple2 + (c', st_d') -> + FStar_Pervasives.Mkdtuple3 + (st, + (comp_st_with_post + c' + (Pulse_Syntax_Base.comp_post + c)), + (simplify_post g1 + st c' st_d' + (Pulse_Syntax_Base.comp_post + c))))))))) uu___) let (k_elab_equiv : Pulse_Typing_Env.env -> @@ -930,7 +906,7 @@ let (continuation_elaborator_with_bind : Pulse_Syntax_Base.st_term -> (unit, unit, unit) Pulse_Typing.st_typing -> unit -> - Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.nvar -> ((unit, unit, unit, unit) continuation_elaborator, unit) FStar_Tactics_Effect.tac_repr) = @@ -961,83 +937,75 @@ let (continuation_elaborator_with_bind : (ctxt, (), ())) with | Prims.Mkdtuple2 (c11, e1_typing1) -> - (match Pulse_Typing_Metatheory.st_comp_typing_inversion + (match Pulse_Typing_Metatheory_Base.st_comp_typing_inversion g (Pulse_Syntax_Base.st_comp_of_comp c11) - (Pulse_Typing_Metatheory.comp_typing_inversion + (Pulse_Typing_Metatheory_Base.comp_typing_inversion g c11 - (Pulse_Typing_Metatheory.st_typing_correctness + (Pulse_Typing_Metatheory_Base.st_typing_correctness g e1 c11 e1_typing1)) with | FStar_Pervasives.Mkdtuple4 (u_of_1, pre_typing, uu___1, uu___2) -> - (fun post_hint -> - fun res -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (228)) - (Prims.of_int (34)) - (Prims.of_int (228)) - (Prims.of_int (37))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (227)) - (Prims.of_int (24)) - (Prims.of_int (260)) - (Prims.of_int (5))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___3 -> res)) - (fun uu___3 -> - (fun uu___3 -> - match uu___3 - with - | FStar_Pervasives.Mkdtuple3 - (e2, c2, - e2_typing) - -> - if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c2) - then - Obj.magic - (Obj.repr - (FStar_Tactics_V2_Derived.fail - "Unexpected non-stateful comp in continuation elaborate")) - else - Obj.magic - (Obj.repr + (match x with + | (ppname, x1) -> + (fun post_hint -> + fun res -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (228)) + (Prims.of_int (34)) + (Prims.of_int (228)) + (Prims.of_int (37))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (227)) + (Prims.of_int (24)) + (Prims.of_int (256)) + (Prims.of_int (5))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___3 -> + res)) + (fun uu___3 -> + (fun uu___3 -> + match uu___3 + with + | FStar_Pervasives.Mkdtuple3 + (e2, c2, + e2_typing) + -> + Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (232)) - (Prims.of_int (43)) - (Prims.of_int (232)) - (Prims.of_int (52))))) + (Prims.of_int (229)) + (Prims.of_int (41)) + (Prims.of_int (229)) + (Prims.of_int (50))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (232)) - (Prims.of_int (55)) - (Prims.of_int (259)) - (Prims.of_int (7))))) + (Prims.of_int (229)) + (Prims.of_int (53)) + (Prims.of_int (256)) + (Prims.of_int (5))))) (FStar_Tactics_Effect.lift_div_tac (fun - uu___5 -> + uu___4 -> e2_typing)) (fun - uu___5 -> + uu___4 -> (fun e2_typing1 -> @@ -1047,70 +1015,74 @@ let (continuation_elaborator_with_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (233)) - (Prims.of_int (22)) - (Prims.of_int (233)) - (Prims.of_int (40))))) + (Prims.of_int (230)) + (Prims.of_int (20)) + (Prims.of_int (230)) + (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (244)) - (Prims.of_int (6)) - (Prims.of_int (259)) - (Prims.of_int (7))))) + (Prims.of_int (241)) + (Prims.of_int (4)) + (Prims.of_int (256)) + (Prims.of_int (5))))) (FStar_Tactics_Effect.lift_div_tac (fun - uu___5 -> + uu___4 -> Pulse_Syntax_Naming.close_st_term - e2 x)) + e2 x1)) (fun - uu___5 -> + uu___4 -> (fun e2_closed -> if FStar_Set.mem - x + x1 (Pulse_Syntax_Naming.freevars (Pulse_Syntax_Base.comp_post c2)) then Obj.magic - (Obj.repr - (FStar_Tactics_V2_Derived.fail - "Impossible")) + (Pulse_Typing_Env.fail + (Pulse_Typing_Env.push_binding + g x1 + ppname + (Pulse_Syntax_Base.comp_res + c1)) + FStar_Pervasives_Native.None + "Impossible: freevar clash when constructing continuation elaborator for bind, please file a bug-report") else Obj.magic - (Obj.repr (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (248)) - (Prims.of_int (10)) - (Prims.of_int (248)) - (Prims.of_int (94))))) + (Prims.of_int (245)) + (Prims.of_int (8)) + (Prims.of_int (245)) + (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (246)) - (Prims.of_int (11)) - (Prims.of_int (259)) - (Prims.of_int (7))))) + (Prims.of_int (243)) + (Prims.of_int (9)) + (Prims.of_int (256)) + (Prims.of_int (5))))) (Obj.magic (Pulse_Typing_Combinators.bind_res_and_post_typing g (Pulse_Syntax_Base.st_comp_of_comp - c2) x + c2) x1 post_hint)) (fun - uu___6 -> + uu___5 -> (fun - uu___6 -> - match uu___6 + uu___5 -> + match uu___5 with | (t_typing, @@ -1122,18 +1094,18 @@ let (continuation_elaborator_with_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (250)) - (Prims.of_int (10)) - (Prims.of_int (256)) - (Prims.of_int (23))))) + (Prims.of_int (247)) + (Prims.of_int (8)) + (Prims.of_int (253)) + (Prims.of_int (21))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (248)) - (Prims.of_int (97)) - (Prims.of_int (258)) - (Prims.of_int (28))))) + (Prims.of_int (245)) + (Prims.of_int (95)) + (Prims.of_int (255)) + (Prims.of_int (26))))) (Obj.magic (Pulse_Typing_Combinators.mk_bind g @@ -1143,18 +1115,18 @@ let (continuation_elaborator_with_bind : c1)) e1 e2_closed c11 c2 - (Pulse_Syntax_Base.v_as_nv - x) + (ppname, + x1) e1_typing1 () e2_typing1 () ())) (fun - uu___7 -> + uu___6 -> FStar_Tactics_Effect.lift_div_tac (fun - uu___8 -> - match uu___7 + uu___7 -> + match uu___6 with | FStar_Pervasives.Mkdtuple3 @@ -1164,10 +1136,10 @@ let (continuation_elaborator_with_bind : FStar_Pervasives.Mkdtuple3 (e, c, e_typing))))) - uu___6)))) uu___5))) - uu___5)))) - uu___3)))))) + uu___4))) + uu___4))) + uu___3))))))) uu___6 uu___5 uu___4 uu___3 uu___2 uu___1 uu___ let (continuation_elaborator_with_tot_bind : Pulse_Typing_Env.env -> @@ -1176,7 +1148,7 @@ let (continuation_elaborator_with_tot_bind : Pulse_Syntax_Base.term -> Pulse_Syntax_Base.term -> unit -> - Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.nvar -> ((unit, unit, unit, unit) continuation_elaborator, unit) FStar_Tactics_Effect.tac_repr) = @@ -1197,69 +1169,40 @@ let (continuation_elaborator_with_tot_bind : Obj.magic (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> - fun post_hint -> - fun uu___1 -> - match uu___1 with - | FStar_Pervasives.Mkdtuple3 - (e2, c2, d2) -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (280)) - (Prims.of_int (2)) - (Prims.of_int (281)) - (Prims.of_int (76))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (312)) - (Prims.of_int (2)) - (Prims.of_int (312)) - (Prims.of_int (15))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c2) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g - (FStar_Pervasives_Native.Some - (e2.Pulse_Syntax_Base.range2)) - "Tm_TotBind: e2 is not a stateful computation")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___3 -> ())))) - (fun uu___2 -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___3 -> - FStar_Pervasives.Mkdtuple3 - ((Pulse_Typing.wr - (Pulse_Syntax_Base.Tm_TotBind - { + (fun uu___ -> + fun post_hint -> + fun uu___1 -> + Obj.magic + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + match uu___1 with + | FStar_Pervasives.Mkdtuple3 + (e2, c2, d2) -> + (match x with + | (ppname, x1) -> + FStar_Pervasives.Mkdtuple3 + ((Pulse_Typing.wr + (Pulse_Syntax_Base.Tm_TotBind + { Pulse_Syntax_Base.head2 = e1; Pulse_Syntax_Base.body2 = (Pulse_Syntax_Naming.close_st_term - e2 x) - })), - (Pulse_Syntax_Naming.open_comp_with - (Pulse_Syntax_Naming.close_comp - c2 x) e1), - (Pulse_Typing.T_TotBind - (g, e1, - (Pulse_Syntax_Naming.close_st_term - e2 x), - t1, c2, x, - (), d2)))))))) - uu___6 uu___5 uu___4 uu___3 uu___2 uu___1 uu___ + e2 x1) + })), + (Pulse_Syntax_Naming.open_comp_with + (Pulse_Syntax_Naming.close_comp + c2 x1) e1), + (Pulse_Typing.T_TotBind + (g, e1, + (Pulse_Syntax_Naming.close_st_term + e2 x1), + t1, c2, + x1, (), + d2))))))) + uu___))) uu___6 uu___5 uu___4 uu___3 + uu___2 uu___1 uu___ let rec (check_equiv_emp : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> unit FStar_Pervasives_Native.option) @@ -1275,18 +1218,23 @@ let rec (check_equiv_emp : | (uu___, uu___1) -> FStar_Pervasives_Native.None) | uu___ -> FStar_Pervasives_Native.None type ('g, 'postuhint, 'x, 't, 'ctxtu) checker_res_matches_post_hint = Obj.t +type ('g, 'postuhint, 'x, 'g1, 't, 'ctxtu) checker_result_inv = Obj.t type ('g, 'ctxt, 'postuhint) checker_result_t = - (Pulse_Syntax_Base.var, Pulse_Syntax_Base.term, Pulse_Syntax_Base.vprop, - Pulse_Typing_Env.env, (unit, unit, unit, unit) continuation_elaborator) + (Pulse_Syntax_Base.var, Pulse_Typing_Env.env, + (Pulse_Syntax_Base.universe, Pulse_Syntax_Base.typ, unit) + FStar_Pervasives.dtuple3, + (Pulse_Syntax_Base.vprop, unit) Prims.dtuple2, + (unit, unit, unit, unit) continuation_elaborator) FStar_Pervasives.dtuple5 type check_t = Pulse_Typing_Env.env -> Pulse_Syntax_Base.vprop -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) checker_result_t, unit) - FStar_Tactics_Effect.tac_repr + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) checker_result_t, unit) + FStar_Tactics_Effect.tac_repr let (intro_comp_typing : Pulse_Typing_Env.env -> Pulse_Syntax_Base.comp_st -> @@ -1307,13 +1255,13 @@ let (intro_comp_typing : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (341)) (Prims.of_int (8)) - (Prims.of_int (341)) (Prims.of_int (52))))) + (Prims.of_int (335)) (Prims.of_int (8)) + (Prims.of_int (335)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (343)) (Prims.of_int (4)) - (Prims.of_int (358)) (Prims.of_int (44))))) + (Prims.of_int (337)) (Prims.of_int (4)) + (Prims.of_int (352)) (Prims.of_int (44))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> fun uu___ -> @@ -1334,17 +1282,17 @@ let (intro_comp_typing : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (345)) + (Prims.of_int (339)) (Prims.of_int (16)) - (Prims.of_int (345)) + (Prims.of_int (339)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (346)) + (Prims.of_int (340)) (Prims.of_int (6)) - (Prims.of_int (346)) + (Prims.of_int (340)) (Prims.of_int (19))))) (Obj.magic (intro_st_comp_typing st)) (fun stc -> @@ -1358,17 +1306,17 @@ let (intro_comp_typing : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (348)) + (Prims.of_int (342)) (Prims.of_int (16)) - (Prims.of_int (348)) + (Prims.of_int (342)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (348)) + (Prims.of_int (342)) (Prims.of_int (42)) - (Prims.of_int (352)) + (Prims.of_int (346)) (Prims.of_int (45))))) (Obj.magic (intro_st_comp_typing st)) (fun uu___ -> @@ -1379,17 +1327,17 @@ let (intro_comp_typing : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (349)) + (Prims.of_int (343)) (Prims.of_int (31)) - (Prims.of_int (349)) + (Prims.of_int (343)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (348)) + (Prims.of_int (342)) (Prims.of_int (42)) - (Prims.of_int (352)) + (Prims.of_int (346)) (Prims.of_int (45))))) (Obj.magic (Pulse_Checker_Pure.core_check_term @@ -1407,10 +1355,68 @@ let (intro_comp_typing : then Obj.magic (Obj.repr - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "Ill-typed inames")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + ( + FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (345)) + (Prims.of_int (23)) + (Prims.of_int (345)) + (Prims.of_int (87))))) + (FStar_Sealed.seal + (Obj.magic + ( + FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (345)) + (Prims.of_int (11)) + (Prims.of_int (345)) + (Prims.of_int (87))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (345)) + (Prims.of_int (66)) + (Prims.of_int (345)) + (Prims.of_int (86))))) + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + ( + Obj.magic + (Pulse_Syntax_Printer.term_to_string + i)) + ( + fun + uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Prims.strcat + "ill-typed inames term " + (Prims.strcat + uu___1 ""))))) + (fun uu___1 -> + (fun uu___1 + -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___1)) + uu___1))) else Obj.magic (Obj.repr @@ -1427,17 +1433,17 @@ let (intro_comp_typing : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (354)) + (Prims.of_int (348)) (Prims.of_int (16)) - (Prims.of_int (354)) + (Prims.of_int (348)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (354)) + (Prims.of_int (348)) (Prims.of_int (42)) - (Prims.of_int (358)) + (Prims.of_int (352)) (Prims.of_int (44))))) (Obj.magic (intro_st_comp_typing st)) (fun uu___ -> @@ -1448,17 +1454,17 @@ let (intro_comp_typing : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (355)) + (Prims.of_int (349)) (Prims.of_int (31)) - (Prims.of_int (355)) + (Prims.of_int (349)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (354)) + (Prims.of_int (348)) (Prims.of_int (42)) - (Prims.of_int (358)) + (Prims.of_int (352)) (Prims.of_int (44))))) (Obj.magic (Pulse_Checker_Pure.core_check_term @@ -1476,10 +1482,68 @@ let (intro_comp_typing : then Obj.magic (Obj.repr - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "Ill-typed inames")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + ( + FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (351)) + (Prims.of_int (23)) + (Prims.of_int (351)) + (Prims.of_int (87))))) + (FStar_Sealed.seal + (Obj.magic + ( + FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (351)) + (Prims.of_int (11)) + (Prims.of_int (351)) + (Prims.of_int (87))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (351)) + (Prims.of_int (66)) + (Prims.of_int (351)) + (Prims.of_int (86))))) + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + ( + Obj.magic + (Pulse_Syntax_Printer.term_to_string + i)) + ( + fun + uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Prims.strcat + "ill-typed inames term " + (Prims.strcat + uu___1 ""))))) + (fun uu___1 -> + (fun uu___1 + -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___1)) + uu___1))) else Obj.magic (Obj.repr @@ -1492,297 +1556,301 @@ let (intro_comp_typing : let (return_in_ctxt : Pulse_Typing_Env.env -> Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.vprop -> - unit -> - unit Pulse_Typing.post_hint_opt -> - (unit, unit, unit) Pulse_Typing_Combinators.st_typing_in_ctxt) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.universe -> + Pulse_Syntax_Base.term -> + Pulse_Syntax_Base.vprop -> + unit -> + unit Pulse_Typing.post_hint_opt -> + (unit, unit, unit) + Pulse_Typing_Combinators.st_typing_in_ctxt) = fun g -> fun y -> - fun u -> - fun ty -> - fun ctxt -> - fun ty_typing -> - fun post_hint0 -> - let uu___ = post_hint0 in - match uu___ with - | FStar_Pervasives_Native.Some post_hint -> - let x = Pulse_Typing_Env.fresh g in - let ctag = - match post_hint.Pulse_Typing.ctag_hint with - | FStar_Pervasives_Native.None -> Pulse_Syntax_Base.STT - | FStar_Pervasives_Native.Some ctag1 -> ctag1 in - let d = - Pulse_Typing.T_Return - (g, ctag, false, u, ty, - (Pulse_Syntax_Pure.null_var y), - (post_hint.Pulse_Typing.post), x, (), (), ()) in - let t = - Pulse_Typing.wr - (Pulse_Syntax_Base.Tm_Return - { - Pulse_Syntax_Base.ctag = ctag; - Pulse_Syntax_Base.insert_eq = false; - Pulse_Syntax_Base.term = - (Pulse_Syntax_Pure.null_var y) - }) in - let c = - Pulse_Typing.comp_return ctag false u ty - (Pulse_Syntax_Pure.null_var y) - post_hint.Pulse_Typing.post x in - let d1 = d in FStar_Pervasives.Mkdtuple3 (t, c, d1) + fun y_ppname -> + fun u -> + fun ty -> + fun ctxt -> + fun ty_typing -> + fun post_hint0 -> + let uu___ = post_hint0 in + match uu___ with + | FStar_Pervasives_Native.Some post_hint -> + let x = Pulse_Typing_Env.fresh g in + let ctag = + match post_hint.Pulse_Typing.ctag_hint with + | FStar_Pervasives_Native.None -> + Pulse_Syntax_Base.STT + | FStar_Pervasives_Native.Some ctag1 -> ctag1 in + let y_tm = + Pulse_Syntax_Pure.tm_var + { + Pulse_Syntax_Base.nm_index = y; + Pulse_Syntax_Base.nm_ppname = y_ppname + } in + let d = + Pulse_Typing.T_Return + (g, ctag, false, u, ty, y_tm, + (post_hint.Pulse_Typing.post), x, (), (), ()) in + let t = + Pulse_Typing.wr + (Pulse_Syntax_Base.Tm_Return + { + Pulse_Syntax_Base.ctag = ctag; + Pulse_Syntax_Base.insert_eq = false; + Pulse_Syntax_Base.term = y_tm + }) in + let c = + Pulse_Typing.comp_return ctag false u ty y_tm + post_hint.Pulse_Typing.post x in + let d1 = d in FStar_Pervasives.Mkdtuple3 (t, c, d1) let (apply_checker_result_k : Pulse_Typing_Env.env -> Pulse_Syntax_Base.vprop -> unit Pulse_Typing.post_hint_for_env -> (unit, unit, unit) checker_result_t -> - ((unit, unit, unit) Pulse_Typing_Combinators.st_typing_in_ctxt, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + ((unit, unit, unit) Pulse_Typing_Combinators.st_typing_in_ctxt, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> fun post_hint -> fun r -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (397)) (Prims.of_int (35)) - (Prims.of_int (397)) (Prims.of_int (36))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (394)) (Prims.of_int (55)) - (Prims.of_int (404)) (Prims.of_int (22))))) - (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> r)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple5 (y, ty_y, pre', g1, k) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (399)) (Prims.of_int (29)) - (Prims.of_int (399)) (Prims.of_int (70))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (397)) (Prims.of_int (39)) - (Prims.of_int (404)) (Prims.of_int (22))))) - (Obj.magic - (Pulse_Checker_Pure.check_universe g1 ty_y)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 (u_ty_y, d_ty_y) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (402)) - (Prims.of_int (4)) - (Prims.of_int (402)) - (Prims.of_int (64))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (404)) - (Prims.of_int (2)) - (Prims.of_int (404)) - (Prims.of_int (22))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - return_in_ctxt g1 y u_ty_y - ty_y pre' () - (FStar_Pervasives_Native.Some - post_hint))) - (fun uu___2 -> - (fun d -> - Obj.magic - (k - (FStar_Pervasives_Native.Some - post_hint) d)) uu___2))) - uu___1))) uu___) + fun res_ppname -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Base.fst" + (Prims.of_int (393)) (Prims.of_int (64)) + (Prims.of_int (393)) (Prims.of_int (65))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Base.fst" + (Prims.of_int (390)) (Prims.of_int (55)) + (Prims.of_int (400)) (Prims.of_int (22))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> r)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | FStar_Pervasives.Mkdtuple5 + (y, g1, FStar_Pervasives.Mkdtuple3 + (u_ty, ty_y, d_ty_y), Prims.Mkdtuple2 + (pre', uu___1), k) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (395)) + (Prims.of_int (29)) + (Prims.of_int (395)) + (Prims.of_int (70))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (393)) + (Prims.of_int (68)) + (Prims.of_int (400)) + (Prims.of_int (22))))) + (Obj.magic + (Pulse_Checker_Pure.check_universe g1 ty_y)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 with + | Prims.Mkdtuple2 (u_ty_y, d_ty_y1) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (398)) + (Prims.of_int (4)) + (Prims.of_int (398)) + (Prims.of_int (75))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (400)) + (Prims.of_int (2)) + (Prims.of_int (400)) + (Prims.of_int (22))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___3 -> + return_in_ctxt g1 y + res_ppname u_ty_y ty_y + pre' () + (FStar_Pervasives_Native.Some + post_hint))) + (fun uu___3 -> + (fun d -> + Obj.magic + (k + (FStar_Pervasives_Native.Some + post_hint) d)) + uu___3))) uu___2))) uu___) let (checker_result_for_st_typing : Pulse_Typing_Env.env -> Pulse_Syntax_Base.vprop -> unit Pulse_Typing.post_hint_opt -> (unit, unit, unit) Pulse_Typing_Combinators.st_typing_in_ctxt -> - ((unit, unit, unit) checker_result_t, unit) - FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + ((unit, unit, unit) checker_result_t, unit) + FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> fun post_hint -> fun d -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (411)) (Prims.of_int (22)) - (Prims.of_int (411)) (Prims.of_int (23))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (409)) (Prims.of_int (47)) - (Prims.of_int (437)) (Prims.of_int (35))))) - (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> d)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple3 (t, c, d1) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (413)) (Prims.of_int (2)) - (Prims.of_int (414)) (Prims.of_int (70))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (414)) (Prims.of_int (71)) - (Prims.of_int (437)) (Prims.of_int (35))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp c) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "checker_result_for_st_typing: not a stateful comp")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> ())))) - (fun uu___1 -> - (fun uu___1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (417)) - (Prims.of_int (10)) - (Prims.of_int (417)) - (Prims.of_int (17))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (417)) - (Prims.of_int (20)) - (Prims.of_int (437)) - (Prims.of_int (35))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing_Env.fresh g)) - (fun uu___2 -> - (fun x -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (419)) - (Prims.of_int (11)) - (Prims.of_int (419)) - (Prims.of_int (55))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (419)) - (Prims.of_int (58)) - (Prims.of_int (437)) - (Prims.of_int (35))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing_Env.push_binding - g x - Pulse_Syntax_Base.ppname_default - (Pulse_Syntax_Base.comp_res - c))) - (fun uu___2 -> - (fun g' -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (420)) - (Prims.of_int (14)) - (Prims.of_int (420)) - (Prims.of_int (60))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Base.fst" - (Prims.of_int (420)) - (Prims.of_int (63)) - (Prims.of_int (437)) - (Prims.of_int (35))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Syntax_Naming.open_term_nv - ( - Pulse_Syntax_Base.comp_post - c) - (Pulse_Syntax_Base.ppname_default, - x))) - (fun uu___2 -> - (fun ctxt' -> - Obj.magic + fun ppname -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Base.fst" + (Prims.of_int (408)) (Prims.of_int (22)) + (Prims.of_int (408)) (Prims.of_int (23))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Base.fst" + (Prims.of_int (406)) (Prims.of_int (47)) + (Prims.of_int (437)) (Prims.of_int (72))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> d)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | FStar_Pervasives.Mkdtuple3 (t, c, d1) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (410)) + (Prims.of_int (10)) + (Prims.of_int (410)) + (Prims.of_int (17))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (410)) + (Prims.of_int (20)) + (Prims.of_int (437)) + (Prims.of_int (72))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> Pulse_Typing_Env.fresh g)) + (fun uu___1 -> + (fun x -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (412)) + (Prims.of_int (11)) + (Prims.of_int (412)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (412)) + (Prims.of_int (50)) + (Prims.of_int (437)) + (Prims.of_int (72))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Typing_Env.push_binding g + x ppname + (Pulse_Syntax_Base.comp_res c))) + (fun uu___1 -> + (fun g' -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (413)) + (Prims.of_int (14)) + (Prims.of_int (413)) + (Prims.of_int (52))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Base.fst" + (Prims.of_int (413)) + (Prims.of_int (55)) + (Prims.of_int (437)) + (Prims.of_int (72))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Syntax_Naming.open_term_nv + (Pulse_Syntax_Base.comp_post + c) (ppname, x))) + (fun uu___1 -> + (fun ctxt' -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic ( - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + FStar_Range.mk_range "Pulse.Checker.Base.fst" - (Prims.of_int (425)) + (Prims.of_int (418)) (Prims.of_int (4)) - (Prims.of_int (425)) - (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range + (Prims.of_int (418)) + (Prims.of_int (69))))) + (FStar_Sealed.seal + (Obj.magic + ( + FStar_Range.mk_range "Pulse.Checker.Base.fst" + (Prims.of_int (428)) + (Prims.of_int (30)) (Prims.of_int (437)) - (Prims.of_int (2)) - (Prims.of_int (437)) - (Prims.of_int (35))))) - (Obj.magic - (continuation_elaborator_with_bind + (Prims.of_int (72))))) + (Obj.magic + (continuation_elaborator_with_bind g Pulse_Syntax_Base.tm_emp c t d1 () - x)) - (fun k -> - FStar_Tactics_Effect.lift_div_tac - (fun - uu___2 -> + (ppname, + x))) + (fun k -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___1 -> + match + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion_cofinite + g + (Pulse_Syntax_Base.st_comp_of_comp + c) + (Pulse_Typing_Metatheory_Base.comp_typing_inversion + g c + (Pulse_Typing_Metatheory_Base.st_typing_correctness + g t c d1)) + with + | + (comp_res_typing, + uu___2, + f) -> FStar_Pervasives.Mkdtuple5 - (x, - (Pulse_Syntax_Base.comp_res + (x, g', + (FStar_Pervasives.Mkdtuple3 + ((Pulse_Syntax_Base.comp_u c), - ctxt', - g', + (Pulse_Syntax_Base.comp_res + c), ())), + (Prims.Mkdtuple2 + (ctxt', + ())), (k_elab_equiv g g' (Pulse_Syntax_Base.tm_star @@ -1796,6 +1864,5 @@ let (checker_result_for_st_typing : Pulse_Syntax_Base.tm_emp) ctxt' k () ())))))) - uu___2))) - uu___2))) uu___2))) - uu___1))) uu___) \ No newline at end of file + uu___1))) uu___1))) + uu___1))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Bind.ml b/src/ocaml/plugin/generated/Pulse_Checker_Bind.ml index edda0cf13..10399b14a 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Bind.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Bind.ml @@ -6,176 +6,187 @@ let (check_bind : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> fun ctxt_typing -> fun post_hint -> - fun t -> - fun check -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (27)) (Prims.of_int (2)) - (Prims.of_int (28)) (Prims.of_int (66))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (30)) (Prims.of_int (2)) - (Prims.of_int (43)) (Prims.of_int (32))))) - (Obj.magic - (Pulse_Checker_Prover_Util.debug_prover g - (fun uu___ -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (28)) (Prims.of_int (42)) - (Prims.of_int (28)) (Prims.of_int (65))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "prims.fst" - (Prims.of_int (590)) (Prims.of_int (19)) - (Prims.of_int (590)) (Prims.of_int (31))))) - (Obj.magic - (Pulse_Syntax_Printer.st_term_to_string t)) - (fun uu___1 -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Prims.strcat "checking bind:\n" - (Prims.strcat uu___1 "\n")))))) - (fun uu___ -> - (fun uu___ -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (30)) (Prims.of_int (2)) - (Prims.of_int (31)) (Prims.of_int (80))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (31)) (Prims.of_int (81)) - (Prims.of_int (43)) (Prims.of_int (32))))) - (if FStar_Pervasives_Native.uu___is_None post_hint - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - (FStar_Pervasives_Native.Some - (t.Pulse_Syntax_Base.range2)) - "check_bind: post_hint is None, bailing (t:\n%s\n)")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> ())))) - (fun uu___1 -> - (fun uu___1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (33)) - (Prims.of_int (44)) - (Prims.of_int (33)) - (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (31)) - (Prims.of_int (81)) - (Prims.of_int (43)) - (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - t.Pulse_Syntax_Base.term1)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | Pulse_Syntax_Base.Tm_Bind - { - Pulse_Syntax_Base.binder = - binder; - Pulse_Syntax_Base.head1 = - e1; - Pulse_Syntax_Base.body1 = - e2;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (36)) - (Prims.of_int (4)) - (Prims.of_int (36)) - (Prims.of_int (36))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (33)) - (Prims.of_int (53)) - (Prims.of_int (43)) - (Prims.of_int (32))))) - (Obj.magic - (check g ctxt () - FStar_Pervasives_Native.None - e1)) - (fun uu___3 -> - (fun uu___3 -> - match uu___3 with - | FStar_Pervasives.Mkdtuple5 - (x, ty, ctxt', - g1, k1) - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - ( - FStar_Sealed.seal + fun res_ppname -> + fun t -> + fun check -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Bind.fst" + (Prims.of_int (28)) (Prims.of_int (10)) + (Prims.of_int (28)) (Prims.of_int (62))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Bind.fst" + (Prims.of_int (30)) (Prims.of_int (2)) + (Prims.of_int (47)) (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_bind" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (30)) (Prims.of_int (2)) + (Prims.of_int (31)) (Prims.of_int (66))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (33)) (Prims.of_int (2)) + (Prims.of_int (47)) (Prims.of_int (43))))) + (Obj.magic + (Pulse_Checker_Prover_Util.debug_prover g1 + (fun uu___ -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (31)) + (Prims.of_int (42)) + (Prims.of_int (31)) + (Prims.of_int (65))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.st_term_to_string + t)) + (fun uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Prims.strcat + "checking bind:\n" + (Prims.strcat uu___1 "\n")))))) + (fun uu___ -> + (fun uu___ -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (33)) + (Prims.of_int (2)) + (Prims.of_int (34)) + (Prims.of_int (89))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (34)) + (Prims.of_int (90)) + (Prims.of_int (47)) + (Prims.of_int (43))))) + (if + FStar_Pervasives_Native.uu___is_None + post_hint + then + Obj.magic + (Obj.repr + (Pulse_Typing_Env.fail g1 + (FStar_Pervasives_Native.Some + (t.Pulse_Syntax_Base.range2)) + "check_bind: post hint is not set, please add an annotation")) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> ())))) + (fun uu___1 -> + (fun uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (36)) + (Prims.of_int (44)) + (Prims.of_int (36)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (34)) + (Prims.of_int (90)) + (Prims.of_int (47)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + t.Pulse_Syntax_Base.term1)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 with + | Pulse_Syntax_Base.Tm_Bind + { + Pulse_Syntax_Base.binder + = binder; + Pulse_Syntax_Base.head1 + = e1; + Pulse_Syntax_Base.body1 + = e2;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" (Prims.of_int (39)) (Prims.of_int (4)) (Prims.of_int (39)) - (Prims.of_int (86))))) - ( - FStar_Sealed.seal + (Prims.of_int (57))))) + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (39)) - (Prims.of_int (89)) - (Prims.of_int (43)) - (Prims.of_int (32))))) - ( - Obj.magic + (Prims.of_int (36)) + (Prims.of_int (53)) + (Prims.of_int (47)) + (Prims.of_int (43))))) + (Obj.magic (check g1 - ctxt' () - post_hint - (Pulse_Syntax_Naming.open_st_term_nv - e2 - ((binder.Pulse_Syntax_Base.binder_ppname), - x)))) - ( - fun - uu___4 -> - (fun r -> + ctxt () + FStar_Pervasives_Native.None + binder.Pulse_Syntax_Base.binder_ppname + e1)) + (fun uu___3 + -> + (fun + uu___3 -> + match uu___3 + with + | + FStar_Pervasives.Mkdtuple5 + (x, g11, + uu___4, + Prims.Mkdtuple2 + (ctxt', + ctxt'_typing), + k1) -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal @@ -183,25 +194,85 @@ let (check_bind : (FStar_Range.mk_range "Pulse.Checker.Bind.fst" (Prims.of_int (40)) - (Prims.of_int (49)) - (Prims.of_int (40)) - (Prims.of_int (100))))) + (Prims.of_int (48)) + (Prims.of_int (44)) + (Prims.of_int (64))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (40)) - (Prims.of_int (103)) + (Prims.of_int (44)) + (Prims.of_int (67)) + (Prims.of_int (47)) + (Prims.of_int (43))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (41)) + (Prims.of_int (17)) + (Prims.of_int (41)) + (Prims.of_int (45))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (41)) + (Prims.of_int (48)) + (Prims.of_int (44)) + (Prims.of_int (64))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_bind_c")) + (fun + uu___5 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (43)) + (Prims.of_int (6)) (Prims.of_int (43)) - (Prims.of_int (32))))) + (Prims.of_int (97))))) + (FStar_Sealed.seal (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (44)) + (Prims.of_int (6)) + (Prims.of_int (44)) + (Prims.of_int (64))))) + (Obj.magic + (check + g11 ctxt' + () + post_hint + ppname + (Pulse_Syntax_Naming.open_st_term_nv + e2 + ((binder.Pulse_Syntax_Base.binder_ppname), + x)))) + (fun + uu___5 -> + (fun r -> + Obj.magic (Pulse_Checker_Base.apply_checker_result_k - g1 ctxt' + g11 ctxt' (FStar_Pervasives_Native.__proj__Some__item__v post_hint) - r)) + r ppname)) + uu___5))) + uu___5))) (fun - uu___4 -> + uu___5 -> (fun d -> Obj.magic (FStar_Tactics_Effect.tac_bind @@ -209,190 +280,226 @@ let (check_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (41)) + (Prims.of_int (45)) (Prims.of_int (47)) - (Prims.of_int (41)) + (Prims.of_int (45)) (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (43)) + (Prims.of_int (47)) (Prims.of_int (2)) - (Prims.of_int (43)) - (Prims.of_int (32))))) + (Prims.of_int (47)) + (Prims.of_int (43))))) (Obj.magic (k1 post_hint d)) (fun - uu___4 -> + uu___5 -> (fun d1 -> Obj.magic (Pulse_Checker_Base.checker_result_for_st_typing - g ctxt + g1 ctxt post_hint - d1)) - uu___4))) - uu___4))) - uu___4))) - uu___3))) uu___2))) - uu___1))) uu___) + d1 + res_ppname)) + uu___5))) + uu___5))) + uu___3))) + uu___2))) uu___1))) + uu___))) uu___) let (check_tot_bind : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - fun check -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (54)) (Prims.of_int (2)) - (Prims.of_int (55)) (Prims.of_int (84))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (55)) (Prims.of_int (85)) - (Prims.of_int (79)) (Prims.of_int (32))))) - (if FStar_Pervasives_Native.uu___is_None post_hint - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - (FStar_Pervasives_Native.Some - (t.Pulse_Syntax_Base.range2)) - "check_tot_bind: post_hint is None, bailing (t:\n%s\n)")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> ())))) - (fun uu___ -> - (fun uu___ -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (57)) (Prims.of_int (40)) - (Prims.of_int (57)) (Prims.of_int (46))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (55)) (Prims.of_int (85)) - (Prims.of_int (79)) (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> t.Pulse_Syntax_Base.term1)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Pulse_Syntax_Base.Tm_TotBind - { Pulse_Syntax_Base.head2 = e1; - Pulse_Syntax_Base.body2 = e2;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (58)) - (Prims.of_int (48)) - (Prims.of_int (58)) - (Prims.of_int (72))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (57)) - (Prims.of_int (49)) - (Prims.of_int (79)) - (Prims.of_int (32))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_and_type - g e1)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | FStar_Pervasives.Mkdtuple5 - (e11, u1, t1, _t1_typing, - e1_typing) - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (59)) - (Prims.of_int (10)) - (Prims.of_int (62)) - (Prims.of_int (21))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Bind.fst" - (Prims.of_int (62)) - (Prims.of_int (24)) - (Prims.of_int (79)) - (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___3 -> - Pulse_Syntax_Pure.tm_refine - { - Pulse_Syntax_Base.binder_ty + fun res_ppname -> + fun t -> + fun check -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Bind.fst" + (Prims.of_int (59)) (Prims.of_int (10)) + (Prims.of_int (59)) (Prims.of_int (62))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Bind.fst" + (Prims.of_int (61)) (Prims.of_int (2)) + (Prims.of_int (88)) (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_bind" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (61)) (Prims.of_int (2)) + (Prims.of_int (62)) (Prims.of_int (93))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (62)) (Prims.of_int (94)) + (Prims.of_int (88)) (Prims.of_int (43))))) + (if + FStar_Pervasives_Native.uu___is_None + post_hint + then + Obj.magic + (Obj.repr + (Pulse_Typing_Env.fail g1 + (FStar_Pervasives_Native.Some + (t.Pulse_Syntax_Base.range2)) + "check_tot_bind: post hint is not set, please add an annotation")) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> ())))) + (fun uu___ -> + (fun uu___ -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (64)) + (Prims.of_int (40)) + (Prims.of_int (64)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (62)) + (Prims.of_int (94)) + (Prims.of_int (88)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + t.Pulse_Syntax_Base.term1)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Pulse_Syntax_Base.Tm_TotBind + { + Pulse_Syntax_Base.head2 = + e1; + Pulse_Syntax_Base.body2 = + e2;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (65)) + (Prims.of_int (48)) + (Prims.of_int (65)) + (Prims.of_int (72))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (64)) + (Prims.of_int (49)) + (Prims.of_int (88)) + (Prims.of_int (43))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_and_type + g1 e1)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 + with + | FStar_Pervasives.Mkdtuple5 + (e11, u1, + t1, + _t1_typing, + e1_typing) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (66)) + (Prims.of_int (10)) + (Prims.of_int (69)) + (Prims.of_int (21))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (69)) + (Prims.of_int (24)) + (Prims.of_int (88)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Pulse_Syntax_Pure.tm_refine + { + Pulse_Syntax_Base.binder_ty = t1; - Pulse_Syntax_Base.binder_ppname + Pulse_Syntax_Base.binder_ppname = Pulse_Syntax_Base.ppname_default - } - (Pulse_Typing.mk_eq2 + } + (Pulse_Typing.mk_eq2 u1 t1 - ( - Pulse_Syntax_Pure.null_bvar + (Pulse_Syntax_Pure.null_bvar Prims.int_zero) e11))) - (fun uu___3 -> - (fun t11 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - ( - FStar_Sealed.seal + (fun + uu___3 -> + (fun t11 + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (66)) + (Prims.of_int (73)) (Prims.of_int (4)) - (Prims.of_int (66)) + (Prims.of_int (73)) (Prims.of_int (41))))) - ( - FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (62)) + (Prims.of_int (69)) (Prims.of_int (24)) - (Prims.of_int (79)) - (Prims.of_int (32))))) - ( - Obj.magic + (Prims.of_int (88)) + (Prims.of_int (43))))) + (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type - g e11 t11)) - ( - fun + g1 e11 + t11)) + (fun uu___3 -> (fun uu___3 -> @@ -409,23 +516,23 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (10)) - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (17))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (20)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (88)) + (Prims.of_int (43))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> Pulse_Typing_Env.fresh - g)) + g1)) (fun uu___4 -> (fun x -> @@ -435,23 +542,25 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (70)) + (Prims.of_int (77)) (Prims.of_int (10)) - (Prims.of_int (70)) - (Prims.of_int (74))))) + (Prims.of_int (77)) + (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (70)) (Prims.of_int (77)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (95)) + (Prims.of_int (88)) + (Prims.of_int (43))))) (Obj.magic (Pulse_Checker_Base.continuation_elaborator_with_tot_bind g pre () e12 t11 - () x)) + () + (Pulse_Syntax_Base.ppname_default, + x))) (fun uu___4 -> (fun k -> @@ -461,18 +570,18 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (72)) + (Prims.of_int (79)) (Prims.of_int (11)) - (Prims.of_int (72)) + (Prims.of_int (79)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (72)) - (Prims.of_int (23)) (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (23)) + (Prims.of_int (88)) + (Prims.of_int (43))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -488,23 +597,23 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (73)) + (Prims.of_int (80)) (Prims.of_int (11)) - (Prims.of_int (73)) + (Prims.of_int (80)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (73)) + (Prims.of_int (80)) (Prims.of_int (42)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (88)) + (Prims.of_int (43))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> Pulse_Typing_Env.push_binding - g x + g1 x (FStar_Pervasives_Native.fst px) t11)) (fun @@ -517,18 +626,18 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (75)) + (Prims.of_int (82)) (Prims.of_int (4)) - (Prims.of_int (75)) - (Prims.of_int (52))))) + (Prims.of_int (82)) + (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (75)) - (Prims.of_int (55)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (82)) + (Prims.of_int (61)) + (Prims.of_int (88)) + (Prims.of_int (43))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -544,51 +653,81 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (76)) - (Prims.of_int (10)) - (Prims.of_int (76)) - (Prims.of_int (68))))) + (Prims.of_int (83)) + (Prims.of_int (9)) + (Prims.of_int (86)) + (Prims.of_int (62))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (76)) - (Prims.of_int (71)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (86)) + (Prims.of_int (65)) + (Prims.of_int (88)) + (Prims.of_int (43))))) (Obj.magic - (check g' - pre () - post_hint - (Pulse_Syntax_Naming.open_st_term_nv - e2 px))) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (84)) + (Prims.of_int (17)) + (Prims.of_int (84)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Bind.fst" + (Prims.of_int (84)) + (Prims.of_int (49)) + (Prims.of_int (86)) + (Prims.of_int (62))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> - (fun r -> + Pulse_Syntax_Base.mk_ppname_no_range + "_tbind_c")) + (fun + uu___4 -> + (fun + ppname -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (77)) - (Prims.of_int (10)) - (Prims.of_int (77)) - (Prims.of_int (61))))) + (Prims.of_int (85)) + (Prims.of_int (12)) + (Prims.of_int (85)) + (Prims.of_int (77))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (77)) - (Prims.of_int (64)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (86)) + (Prims.of_int (4)) + (Prims.of_int (86)) + (Prims.of_int (62))))) (Obj.magic + (check g' + pre () + post_hint + ppname + (Pulse_Syntax_Naming.open_st_term_nv + e2 px))) + (fun + uu___4 -> + (fun r -> + Obj.magic (Pulse_Checker_Base.apply_checker_result_k g' pre (FStar_Pervasives_Native.__proj__Some__item__v post_hint) - r)) + r ppname)) + uu___4))) + uu___4))) (fun uu___4 -> (fun d -> @@ -598,18 +737,18 @@ let (check_tot_bind : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (78)) + (Prims.of_int (87)) (Prims.of_int (10)) - (Prims.of_int (78)) + (Prims.of_int (87)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Bind.fst" - (Prims.of_int (79)) + (Prims.of_int (88)) (Prims.of_int (2)) - (Prims.of_int (79)) - (Prims.of_int (32))))) + (Prims.of_int (88)) + (Prims.of_int (43))))) (Obj.magic (k post_hint @@ -622,8 +761,8 @@ let (check_tot_bind : (Pulse_Checker_Base.checker_result_for_st_typing g pre post_hint - d1)) - uu___4))) + d1 + res_ppname)) uu___4))) uu___4))) uu___4))) @@ -632,5 +771,6 @@ let (check_tot_bind : uu___4))) uu___4))) uu___3))) - uu___3))) - uu___2))) uu___1))) uu___) \ No newline at end of file + uu___3))) + uu___2))) uu___1))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Comp.ml b/src/ocaml/plugin/generated/Pulse_Checker_Comp.ml index ec5e7d6a5..0a3d043c3 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Comp.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Comp.ml @@ -13,135 +13,273 @@ let (check : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (18)) (Prims.of_int (7)) (Prims.of_int (33)) - (Prims.of_int (9))))) + (Prims.of_int (14)) (Prims.of_int (12)) + (Prims.of_int (14)) (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (35)) (Prims.of_int (4)) (Prims.of_int (50)) - (Prims.of_int (44))))) + (Prims.of_int (14)) (Prims.of_int (69)) + (Prims.of_int (63)) (Prims.of_int (44))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> - fun st -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (18)) (Prims.of_int (27)) - (Prims.of_int (18)) (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (18)) (Prims.of_int (7)) - (Prims.of_int (33)) (Prims.of_int (9))))) - (Obj.magic - (Pulse_Checker_Pure.check_universe g - st.Pulse_Syntax_Base.res)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 (u, t_u) -> - if - Prims.op_Negation - (Pulse_Syntax_Base.eq_univ u - (Pulse_Syntax_Base.comp_u c)) - then - Obj.magic - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Unexpected universe") - else - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Comp.fst" - (Prims.of_int (22)) - (Prims.of_int (18)) - (Prims.of_int (22)) - (Prims.of_int (25))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Comp.fst" - (Prims.of_int (22)) - (Prims.of_int (28)) - (Prims.of_int (32)) - (Prims.of_int (11))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___3 -> - Pulse_Typing_Env.fresh g)) - (fun uu___3 -> - (fun x -> + Pulse_Typing_Env.push_context_no_range g "check_comp")) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Comp.fst" + (Prims.of_int (21)) (Prims.of_int (7)) + (Prims.of_int (42)) (Prims.of_int (9))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Comp.fst" + (Prims.of_int (44)) (Prims.of_int (4)) + (Prims.of_int (63)) (Prims.of_int (44))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + fun st -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (21)) + (Prims.of_int (27)) + (Prims.of_int (21)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (21)) + (Prims.of_int (7)) + (Prims.of_int (42)) + (Prims.of_int (9))))) + (Obj.magic + (Pulse_Checker_Pure.check_universe g1 + st.Pulse_Syntax_Base.res)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 (u, t_u) -> + if + Prims.op_Negation + (Pulse_Syntax_Base.eq_univ u + (Pulse_Syntax_Base.comp_u c)) + then Obj.magic (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (24)) + (Prims.of_int (14)) + (Prims.of_int (27)) + (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" (Prims.of_int (23)) - (Prims.of_int (19)) - (Prims.of_int (23)) - (Prims.of_int (28))))) + (Prims.of_int (13)) + (Prims.of_int (27)) + (Prims.of_int (47))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (24)) + (Prims.of_int (14)) + (Prims.of_int (27)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (24)) + (Prims.of_int (14)) + (Prims.of_int (27)) + (Prims.of_int (47))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (24)) + (Prims.of_int (14)) + (Prims.of_int (27)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (24)) + (Prims.of_int (14)) + (Prims.of_int (27)) + (Prims.of_int (47))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (25)) + (Prims.of_int (17)) + (Prims.of_int (25)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + st.Pulse_Syntax_Base.res)) + (fun uu___2 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + fun x -> + fun x1 -> + Prims.strcat + (Prims.strcat + (Prims.strcat + "check_comp: computed universe of " + (Prims.strcat + uu___2 + " as ")) + (Prims.strcat + x + ", whereas annotated as ")) + (Prims.strcat + x1 ""))))) + (fun uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___3 + -> + uu___2 + (Pulse_Syntax_Printer.univ_to_string + u))))) + (fun uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___3 -> + uu___2 + (Pulse_Syntax_Printer.univ_to_string + (Pulse_Syntax_Base.comp_u + c)))))) + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + FStar_Pervasives_Native.None + uu___2)) uu___2)) + else + Obj.magic + (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (24)) - (Prims.of_int (57)) - (Prims.of_int (32)) + (Prims.of_int (30)) + (Prims.of_int (18)) + (Prims.of_int (30)) + (Prims.of_int (25))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (30)) + (Prims.of_int (28)) + (Prims.of_int (41)) (Prims.of_int (11))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> - Pulse_Syntax_Base.v_as_nv - x)) + Pulse_Typing_Env.fresh + g1)) (fun uu___3 -> - (fun px -> + (fun x -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (25)) + (Prims.of_int (31)) (Prims.of_int (19)) - (Prims.of_int (25)) - (Prims.of_int (51))))) + (Prims.of_int (31)) + (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (25)) - (Prims.of_int (54)) (Prims.of_int (32)) + (Prims.of_int (57)) + (Prims.of_int (41)) (Prims.of_int (11))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> - Pulse_Typing_Env.push_binding - g x - (FStar_Pervasives_Native.fst - px) - st.Pulse_Syntax_Base.res)) + Pulse_Syntax_Base.v_as_nv + x)) (fun uu___3 -> - (fun gx -> + (fun px -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (26)) + (Prims.of_int (33)) + (Prims.of_int (19)) + (Prims.of_int (33)) + (Prims.of_int (51))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (33)) + (Prims.of_int (54)) + (Prims.of_int (41)) + (Prims.of_int (11))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Pulse_Typing_Env.push_binding + g1 x + (FStar_Pervasives_Native.fst + px) + st.Pulse_Syntax_Base.res)) + (fun + uu___3 -> + (fun gx + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (34)) (Prims.of_int (38)) - (Prims.of_int (26)) + (Prims.of_int (34)) (Prims.of_int (88))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (25)) + (Prims.of_int (33)) (Prims.of_int (54)) - (Prims.of_int (32)) + (Prims.of_int (41)) (Prims.of_int (11))))) (Obj.magic (Pulse_Checker_Pure.core_check_term @@ -168,10 +306,64 @@ let (check : then Obj.magic (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (37)) + (Prims.of_int (17)) + (Prims.of_int (37)) + (Prims.of_int (107))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (36)) + (Prims.of_int (15)) + (Prims.of_int (37)) + (Prims.of_int (107))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (37)) + (Prims.of_int (74)) + (Prims.of_int (37)) + (Prims.of_int (106))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + (Pulse_Syntax_Base.comp_post + c))) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + Prims.strcat + "check_comp: ill-typed postcondition " + (Prims.strcat + uu___4 ""))))) + (fun + uu___4 -> + (fun + uu___4 -> + Obj.magic (Pulse_Typing_Env.fail - g + g1 FStar_Pervasives_Native.None - "Ill-typed postcondition")) + uu___4)) + uu___4))) else Obj.magic (Obj.repr @@ -179,150 +371,510 @@ let (check : (fun uu___5 -> Pulse_Typing.STC - (g, st, + (g1, st, x, (), (), ()))))) uu___3))) + uu___3))) uu___3))) - uu___3))) uu___3))) - uu___1))) - (fun uu___ -> - (fun check_st_comp -> - match c with - | Pulse_Syntax_Base.C_ST st -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (37)) (Prims.of_int (16)) - (Prims.of_int (37)) (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (38)) (Prims.of_int (6)) - (Prims.of_int (38)) (Prims.of_int (19))))) - (Obj.magic (check_st_comp st)) - (fun stc -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> Pulse_Typing.CT_ST (g, st, stc)))) - | Pulse_Syntax_Base.C_STAtomic (i, st) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (40)) (Prims.of_int (16)) - (Prims.of_int (40)) (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (40)) (Prims.of_int (35)) - (Prims.of_int (44)) (Prims.of_int (45))))) - (Obj.magic (check_st_comp st)) - (fun uu___ -> - (fun stc -> + uu___3))) uu___1))) + (fun uu___ -> + (fun check_st_comp -> + match c with + | Pulse_Syntax_Base.C_ST st -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (46)) + (Prims.of_int (16)) + (Prims.of_int (46)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (47)) + (Prims.of_int (6)) + (Prims.of_int (47)) + (Prims.of_int (19))))) + (Obj.magic (check_st_comp st)) + (fun stc -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing.CT_ST (g1, st, stc)))) + | Pulse_Syntax_Base.C_STAtomic (i, st) -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (41)) - (Prims.of_int (31)) - (Prims.of_int (41)) - (Prims.of_int (50))))) + (Prims.of_int (49)) + (Prims.of_int (16)) + (Prims.of_int (49)) + (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (40)) + (Prims.of_int (49)) (Prims.of_int (35)) - (Prims.of_int (44)) + (Prims.of_int (55)) (Prims.of_int (45))))) - (Obj.magic - (Pulse_Checker_Pure.core_check_term g - i)) + (Obj.magic (check_st_comp st)) (fun uu___ -> - (fun uu___ -> - match uu___ with - | Prims.Mkdtuple2 (ty, i_typing) -> - if - Prims.op_Negation - (Pulse_Syntax_Base.eq_tm ty - Pulse_Syntax_Base.tm_inames) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Ill-typed inames")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing.CT_STAtomic - (g, i, st, (), - stc))))) uu___))) - uu___)) - | Pulse_Syntax_Base.C_STGhost (i, st) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (46)) (Prims.of_int (16)) - (Prims.of_int (46)) (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (46)) (Prims.of_int (35)) - (Prims.of_int (50)) (Prims.of_int (44))))) - (Obj.magic (check_st_comp st)) - (fun uu___ -> - (fun stc -> + (fun stc -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (50)) + (Prims.of_int (31)) + (Prims.of_int (50)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (49)) + (Prims.of_int (35)) + (Prims.of_int (55)) + (Prims.of_int (45))))) + (Obj.magic + (Pulse_Checker_Pure.core_check_term + g1 i)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Prims.Mkdtuple2 + (ty, i_typing) -> + if + Prims.op_Negation + (Pulse_Syntax_Base.eq_tm + ty + Pulse_Syntax_Base.tm_inames) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (52)) + (Prims.of_int (11)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (54)) + (Prims.of_int (59)) + (Prims.of_int (54)) + (Prims.of_int (87))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + Pulse_Syntax_Base.tm_inames)) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (54)) + (Prims.of_int (37)) + (Prims.of_int (54)) + (Prims.of_int (58))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + ty)) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (53)) + (Prims.of_int (13)) + (Prims.of_int (54)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (54)) + (Prims.of_int (16)) + (Prims.of_int (54)) + (Prims.of_int (36))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + i)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + fun x -> + fun x1 -> + Prims.strcat + (Prims.strcat + (Prims.strcat + "check_comp: type of inames term " + (Prims.strcat + uu___3 + " is ")) + (Prims.strcat + x + ", expected ")) + (Prims.strcat + x1 ""))))) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + uu___3 + uu___2)))) + uu___2))) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + uu___2 + uu___1)))) + uu___1))) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + FStar_Pervasives_Native.None + uu___1)) + uu___1))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Pulse_Typing.CT_STAtomic + (g1, i, + st, (), + stc))))) + uu___))) uu___)) + | Pulse_Syntax_Base.C_STGhost (i, st) -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (47)) - (Prims.of_int (31)) - (Prims.of_int (47)) - (Prims.of_int (50))))) + (Prims.of_int (57)) + (Prims.of_int (16)) + (Prims.of_int (57)) + (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Comp.fst" - (Prims.of_int (46)) + (Prims.of_int (57)) (Prims.of_int (35)) - (Prims.of_int (50)) + (Prims.of_int (63)) (Prims.of_int (44))))) - (Obj.magic - (Pulse_Checker_Pure.core_check_term g - i)) + (Obj.magic (check_st_comp st)) (fun uu___ -> - (fun uu___ -> - match uu___ with - | Prims.Mkdtuple2 (ty, i_typing) -> - if - Prims.op_Negation - (Pulse_Syntax_Base.eq_tm ty - Pulse_Syntax_Base.tm_inames) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Ill-typed inames")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing.CT_STGhost - (g, i, st, (), - stc))))) uu___))) - uu___))) uu___) \ No newline at end of file + (fun stc -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (58)) + (Prims.of_int (31)) + (Prims.of_int (58)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (57)) + (Prims.of_int (35)) + (Prims.of_int (63)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Checker_Pure.core_check_term + g1 i)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Prims.Mkdtuple2 + (ty, i_typing) -> + if + Prims.op_Negation + (Pulse_Syntax_Base.eq_tm + ty + Pulse_Syntax_Base.tm_inames) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (60)) + (Prims.of_int (11)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (62)) + (Prims.of_int (59)) + (Prims.of_int (62)) + (Prims.of_int (87))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + Pulse_Syntax_Base.tm_inames)) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (62)) + (Prims.of_int (37)) + (Prims.of_int (62)) + (Prims.of_int (58))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + ty)) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (61)) + (Prims.of_int (13)) + (Prims.of_int (62)) + (Prims.of_int (88))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Comp.fst" + (Prims.of_int (62)) + (Prims.of_int (16)) + (Prims.of_int (62)) + (Prims.of_int (36))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + i)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + fun x -> + fun x1 -> + Prims.strcat + (Prims.strcat + (Prims.strcat + "check_comp: type of inames term " + (Prims.strcat + uu___3 + " is ")) + (Prims.strcat + x + ", expected ")) + (Prims.strcat + x1 ""))))) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + uu___3 + uu___2)))) + uu___2))) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + uu___2 + uu___1)))) + uu___1))) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + FStar_Pervasives_Native.None + uu___1)) + uu___1))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Pulse_Typing.CT_STGhost + (g1, i, + st, (), + stc))))) + uu___))) uu___))) uu___))) + uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Exists.ml b/src/ocaml/plugin/generated/Pulse_Checker_Exists.ml index b958cba0a..163f54254 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Exists.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Exists.ml @@ -26,153 +26,185 @@ let (check_elim_exists : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (35)) (Prims.of_int (32)) - (Prims.of_int (35)) (Prims.of_int (38))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (33)) (Prims.of_int (46)) - (Prims.of_int (66)) (Prims.of_int (60))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_ElimExists - { Pulse_Syntax_Base.p1 = t1;_} -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (37)) (Prims.of_int (4)) - (Prims.of_int (53)) (Prims.of_int (21))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (35)) (Prims.of_int (41)) - (Prims.of_int (66)) (Prims.of_int (60))))) - (match t1.Pulse_Syntax_Base.t with - | Pulse_Syntax_Base.Tm_Unknown -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (40)) - (Prims.of_int (15)) - (Prims.of_int (40)) - (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (40)) - (Prims.of_int (35)) - (Prims.of_int (49)) - (Prims.of_int (41))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Typing_Combinators.vprop_as_list - pre)) - (fun uu___1 -> - (fun ts -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (41)) - (Prims.of_int (22)) - (Prims.of_int (41)) - (Prims.of_int (110))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (42)) - (Prims.of_int (6)) - (Prims.of_int (49)) - (Prims.of_int (41))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - FStar_List_Tot_Base.filter - (fun uu___2 -> - match uu___2 - with - | { - Pulse_Syntax_Base.t - = - Pulse_Syntax_Base.Tm_ExistsSL - (uu___3, + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (36)) (Prims.of_int (10)) + (Prims.of_int (36)) (Prims.of_int (69))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (36)) (Prims.of_int (72)) + (Prims.of_int (73)) (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_elim_exists" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (38)) (Prims.of_int (32)) + (Prims.of_int (38)) (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (36)) (Prims.of_int (72)) + (Prims.of_int (73)) (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_ElimExists + { Pulse_Syntax_Base.p1 = t1;_} -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (40)) + (Prims.of_int (4)) + (Prims.of_int (56)) + (Prims.of_int (21))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (38)) + (Prims.of_int (41)) + (Prims.of_int (73)) + (Prims.of_int (55))))) + (match t1.Pulse_Syntax_Base.t with + | Pulse_Syntax_Base.Tm_Unknown -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (43)) + (Prims.of_int (15)) + (Prims.of_int (43)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (43)) + (Prims.of_int (35)) + (Prims.of_int (52)) + (Prims.of_int (41))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Typing_Combinators.vprop_as_list + pre)) + (fun uu___1 -> + (fun ts -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (44)) + (Prims.of_int (22)) + (Prims.of_int (44)) + (Prims.of_int (110))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (45)) + (Prims.of_int (6)) + (Prims.of_int (52)) + (Prims.of_int (41))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 + -> + FStar_List_Tot_Base.filter + (fun + uu___2 -> + match uu___2 + with + | + { + Pulse_Syntax_Base.t + = + Pulse_Syntax_Base.Tm_ExistsSL + (uu___3, uu___4, uu___5); - Pulse_Syntax_Base.range1 - = uu___6;_} - -> true - | uu___3 -> - false) ts)) - (fun uu___1 -> - (fun exist_tms -> - match exist_tms with - | one::[] -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - ( - fun + Pulse_Syntax_Base.range1 + = uu___6;_} + -> true + | + uu___3 -> + false) ts)) + (fun uu___1 -> + (fun + exist_tms + -> + match exist_tms + with + | + one::[] + -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> Prims.Mkdtuple2 (one, ())))) - | uu___1 -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - ( - FStar_Sealed.seal + | + uu___1 -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (48)) + (Prims.of_int (51)) (Prims.of_int (10)) - (Prims.of_int (49)) + (Prims.of_int (52)) (Prims.of_int (41))))) - ( - FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (47)) + (Prims.of_int (50)) (Prims.of_int (8)) - (Prims.of_int (49)) + (Prims.of_int (52)) (Prims.of_int (41))))) - ( - Obj.magic + (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (49)) + (Prims.of_int (52)) (Prims.of_int (13)) - (Prims.of_int (49)) + (Prims.of_int (52)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic @@ -194,134 +226,200 @@ let (check_elim_exists : "Could not decide which exists term to eliminate: choices are\n" (Prims.strcat uu___2 ""))))) - ( - fun + (fun uu___2 -> (fun uu___2 -> Obj.magic (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None + g1 + (FStar_Pervasives_Native.Some + (t1.Pulse_Syntax_Base.range1)) uu___2)) uu___2)))) - uu___1))) uu___1)) - | uu___1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (52)) - (Prims.of_int (17)) - (Prims.of_int (52)) - (Prims.of_int (47))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (51)) - (Prims.of_int (10)) - (Prims.of_int (53)) - (Prims.of_int (21))))) - (Obj.magic - (Pulse_Checker_Pure.instantiate_term_implicits - g t1)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | (t2, uu___3) -> - Obj.magic - (Pulse_Checker_Pure.check_vprop - g t2)) uu___2))) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 (t2, t_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (56)) - (Prims.of_int (2)) - (Prims.of_int (66)) - (Prims.of_int (60))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (56)) - (Prims.of_int (2)) - (Prims.of_int (66)) - (Prims.of_int (60))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> uu___1)) - (fun uu___2 -> - (fun uu___2 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (56)) - (Prims.of_int (2)) - (Prims.of_int (57)) - (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (57)) - (Prims.of_int (60)) - (Prims.of_int (66)) - (Prims.of_int (60))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.uu___is_Tm_ExistsSL - t2.Pulse_Syntax_Base.t) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "elim_exists argument not a Tm_ExistsSL")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___4 - -> ())))) - (fun uu___3 -> - (fun uu___3 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + uu___1))) + uu___1)) + | uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (55)) + (Prims.of_int (17)) + (Prims.of_int (55)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (54)) + (Prims.of_int (10)) + (Prims.of_int (56)) + (Prims.of_int (21))))) + (Obj.magic + (Pulse_Checker_Pure.instantiate_term_implicits + g1 t1)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 with + | (t2, uu___3) -> + Obj.magic + (Pulse_Checker_Pure.check_vprop + g1 t2)) + uu___2))) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 + (t2, t_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (59)) + (Prims.of_int (2)) + (Prims.of_int (73)) + (Prims.of_int (55))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (59)) + (Prims.of_int (2)) + (Prims.of_int (73)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + uu___1)) + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" (Prims.of_int (59)) + (Prims.of_int (2)) + (Prims.of_int (62)) + (Prims.of_int (33))))) + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (62)) + (Prims.of_int (34)) + (Prims.of_int (73)) + (Prims.of_int (55))))) + ( + if + Prims.op_Negation + (Pulse_Syntax_Base.uu___is_Tm_ExistsSL + t2.Pulse_Syntax_Base.t) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (61)) + (Prims.of_int (9)) + (Prims.of_int (62)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (60)) + (Prims.of_int (7)) + (Prims.of_int (62)) + (Prims.of_int (33))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (62)) + (Prims.of_int (12)) + (Prims.of_int (62)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + t2)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Prims.strcat + "check_elim_exists: elim_exists argument " + (Prims.strcat + uu___3 + " not an existential"))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + (FStar_Pervasives_Native.Some + (t2.Pulse_Syntax_Base.range1)) + uu___3)) + uu___3))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + ())))) + ( + fun + uu___3 -> + (fun + uu___3 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (64)) (Prims.of_int (41)) - (Prims.of_int (59)) + (Prims.of_int (64)) (Prims.of_int (44))))) - (FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (57)) - (Prims.of_int (60)) - (Prims.of_int (66)) - (Prims.of_int (60))))) - (FStar_Tactics_Effect.lift_div_tac + (Prims.of_int (62)) + (Prims.of_int (34)) + (Prims.of_int (73)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> t2.Pulse_Syntax_Base.t)) - (fun uu___4 - -> + (fun + uu___4 -> (fun uu___4 -> match uu___4 @@ -341,21 +439,21 @@ let (check_elim_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (61)) + (Prims.of_int (66)) (Prims.of_int (28)) - (Prims.of_int (61)) + (Prims.of_int (66)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (59)) + (Prims.of_int (64)) (Prims.of_int (47)) - (Prims.of_int (66)) - (Prims.of_int (60))))) + (Prims.of_int (73)) + (Prims.of_int (55))))) (Obj.magic (Pulse_Checker_Pure.check_universe - g ty)) + g1 ty)) (fun uu___6 -> (fun @@ -377,23 +475,23 @@ let (check_elim_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (63)) + (Prims.of_int (68)) (Prims.of_int (15)) - (Prims.of_int (63)) + (Prims.of_int (68)) (Prims.of_int (22))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (63)) + (Prims.of_int (68)) (Prims.of_int (25)) - (Prims.of_int (65)) - (Prims.of_int (60))))) + (Prims.of_int (70)) + (Prims.of_int (80))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> Pulse_Typing_Env.fresh - g)) + g1)) (fun uu___7 -> (fun x -> @@ -403,23 +501,23 @@ let (check_elim_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (64)) + (Prims.of_int (69)) (Prims.of_int (15)) - (Prims.of_int (64)) + (Prims.of_int (69)) (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (65)) + (Prims.of_int (70)) (Prims.of_int (7)) - (Prims.of_int (65)) - (Prims.of_int (60))))) + (Prims.of_int (70)) + (Prims.of_int (80))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> Pulse_Typing.T_ElimExists - (g, u, + (g1, u, ty, p, x, (), ()))) (fun @@ -431,18 +529,18 @@ let (check_elim_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (65)) - (Prims.of_int (14)) - (Prims.of_int (65)) - (Prims.of_int (42))))) + (Prims.of_int (70)) + (Prims.of_int (23)) + (Prims.of_int (70)) + (Prims.of_int (62))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (65)) + (Prims.of_int (70)) (Prims.of_int (7)) - (Prims.of_int (65)) - (Prims.of_int (60))))) + (Prims.of_int (70)) + (Prims.of_int (80))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -459,13 +557,14 @@ let (check_elim_exists : (Pulse_Typing.comp_elim_exists u ty p (Pulse_Syntax_Base.v_as_nv - x)) d)) + x)) d + res_ppname)) (fun uu___7 -> (fun uu___7 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___7 post_hint @@ -476,13 +575,24 @@ let (check_elim_exists : else Obj.magic (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "Universe checking failed in elim_exists")) + g1 + (FStar_Pervasives_Native.Some + (t2.Pulse_Syntax_Base.range1)) + (Prims.strcat + (Prims.strcat + "check_elim_exists: universe checking failed, computed " + (Prims.strcat + (Pulse_Syntax_Printer.univ_to_string + u') + ", expected ")) + (Prims.strcat + (Pulse_Syntax_Printer.univ_to_string + u) "")))) uu___6))) uu___4))) - uu___3))) uu___2))) - uu___1))) uu___) + uu___3))) + uu___2))) + uu___1))) uu___))) uu___) let (intro_exists_witness_singleton : Pulse_Syntax_Base.st_term -> Prims.bool) = fun st -> @@ -513,162 +623,251 @@ let (check_intro_exists_erased : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - unit FStar_Pervasives_Native.option -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + unit FStar_Pervasives_Native.option -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun st -> - fun vprop_typing -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (83)) (Prims.of_int (46)) - (Prims.of_int (83)) (Prims.of_int (53))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (81)) (Prims.of_int (46)) - (Prims.of_int (100)) (Prims.of_int (65))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> st.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_IntroExists - { Pulse_Syntax_Base.erased = uu___1; - Pulse_Syntax_Base.p2 = t; - Pulse_Syntax_Base.witnesses = e::[];_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (85)) - (Prims.of_int (4)) - (Prims.of_int (87)) - (Prims.of_int (26))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (83)) - (Prims.of_int (56)) - (Prims.of_int (100)) - (Prims.of_int (65))))) - (match vprop_typing with - | FStar_Pervasives_Native.Some typing -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Prims.Mkdtuple2 (t, ())))) - | uu___2 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Pure.check_vprop g t))) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | Prims.Mkdtuple2 (t1, t_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (90)) - (Prims.of_int (2)) - (Prims.of_int (91)) - (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (91)) - (Prims.of_int (60)) - (Prims.of_int (100)) - (Prims.of_int (65))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.uu___is_Tm_ExistsSL - t1.Pulse_Syntax_Base.t) - then + fun res_ppname -> + fun st -> + fun vprop_typing -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (91)) (Prims.of_int (10)) + (Prims.of_int (91)) (Prims.of_int (78))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (91)) (Prims.of_int (81)) + (Prims.of_int (112)) (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g + "check_intro_exists_erased" + st.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (93)) (Prims.of_int (46)) + (Prims.of_int (93)) (Prims.of_int (53))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (91)) (Prims.of_int (81)) + (Prims.of_int (112)) + (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> st.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_IntroExists + { Pulse_Syntax_Base.erased = uu___1; + Pulse_Syntax_Base.p2 = t; + Pulse_Syntax_Base.witnesses = e::[];_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (95)) + (Prims.of_int (4)) + (Prims.of_int (97)) + (Prims.of_int (26))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (93)) + (Prims.of_int (56)) + (Prims.of_int (112)) + (Prims.of_int (85))))) + (match vprop_typing with + | FStar_Pervasives_Native.Some + typing -> Obj.magic (Obj.repr - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "elim_exists argument not a Tm_ExistsSL")) - else + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Prims.Mkdtuple2 + (t, ())))) + | uu___2 -> Obj.magic (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___4 -> ())))) - (fun uu___3 -> - (fun uu___3 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (93)) - (Prims.of_int (26)) - (Prims.of_int (93)) - (Prims.of_int (39))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (91)) - (Prims.of_int (60)) - (Prims.of_int (100)) - (Prims.of_int (65))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___4 -> - t1.Pulse_Syntax_Base.t)) - (fun uu___4 -> - (fun uu___4 -> - match uu___4 - with - | Pulse_Syntax_Base.Tm_ExistsSL - (u, b, p) - -> - Obj.magic + (Pulse_Checker_Pure.check_vprop + g1 t))) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 with + | Prims.Mkdtuple2 + (t1, t_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (100)) + (Prims.of_int (2)) + (Prims.of_int (103)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (103)) + (Prims.of_int (34)) + (Prims.of_int (112)) + (Prims.of_int (85))))) + (if + Prims.op_Negation + (Pulse_Syntax_Base.uu___is_Tm_ExistsSL + t1.Pulse_Syntax_Base.t) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (102)) + (Prims.of_int (9)) + (Prims.of_int (103)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (101)) + (Prims.of_int (7)) + (Prims.of_int (103)) + (Prims.of_int (33))))) + (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (96)) + (Prims.of_int (103)) + (Prims.of_int (12)) + (Prims.of_int (103)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + t1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Prims.strcat + "check_intro_exists_erased: vprop " + (Prims.strcat + uu___3 + " is not an existential"))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + (FStar_Pervasives_Native.Some + (st.Pulse_Syntax_Base.range2)) + uu___3)) + uu___3))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + ())))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (105)) + (Prims.of_int (26)) + (Prims.of_int (105)) + (Prims.of_int (39))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (103)) + (Prims.of_int (34)) + (Prims.of_int (112)) + (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + t1.Pulse_Syntax_Base.t)) + (fun + uu___4 -> + (fun + uu___4 -> + match uu___4 + with + | + Pulse_Syntax_Base.Tm_ExistsSL + (u, b, p) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (108)) (Prims.of_int (21)) - (Prims.of_int (96)) + (Prims.of_int (108)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (95)) + (Prims.of_int (107)) (Prims.of_int (47)) - (Prims.of_int (100)) - (Prims.of_int (65))))) + (Prims.of_int (112)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> - Pulse_Typing_Metatheory.tm_exists_inversion - g u + Pulse_Typing_Metatheory_Base.tm_exists_inversion + g1 u b.Pulse_Syntax_Base.binder_ty p () (Pulse_Typing_Env.fresh - g))) + g1))) (fun uu___5 -> (fun @@ -685,21 +884,21 @@ let (check_intro_exists_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (98)) + (Prims.of_int (110)) (Prims.of_int (4)) - (Prims.of_int (98)) + (Prims.of_int (110)) (Prims.of_int (63))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (96)) + (Prims.of_int (108)) (Prims.of_int (95)) - (Prims.of_int (100)) - (Prims.of_int (65))))) + (Prims.of_int (112)) + (Prims.of_int (85))))) (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type - g e + g1 e (Pulse_Typing.mk_erased u b.Pulse_Syntax_Base.binder_ty))) @@ -720,24 +919,24 @@ let (check_intro_exists_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (99)) + (Prims.of_int (111)) (Prims.of_int (10)) - (Prims.of_int (99)) + (Prims.of_int (111)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (100)) + (Prims.of_int (112)) (Prims.of_int (2)) - (Prims.of_int (100)) - (Prims.of_int (65))))) + (Prims.of_int (112)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> Pulse_Typing.T_IntroExistsErased - (g, u, b, - p, e1, + (g1, u, + b, p, e1, (), (), ()))) (fun @@ -749,18 +948,18 @@ let (check_intro_exists_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (100)) - (Prims.of_int (9)) - (Prims.of_int (100)) - (Prims.of_int (37))))) + (Prims.of_int (112)) + (Prims.of_int (18)) + (Prims.of_int (112)) + (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (100)) + (Prims.of_int (112)) (Prims.of_int (2)) - (Prims.of_int (100)) - (Prims.of_int (65))))) + (Prims.of_int (112)) + (Prims.of_int (85))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -778,13 +977,14 @@ let (check_intro_exists_erased : })) (Pulse_Typing.comp_intro_exists_erased u b p e1) - d)) + d + res_ppname)) (fun uu___8 -> (fun uu___8 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___8 post_hint @@ -793,169 +993,263 @@ let (check_intro_exists_erased : uu___8))) uu___7))) uu___5))) - uu___4))) - uu___3))) uu___2))) uu___) + uu___4))) + uu___3))) + uu___2))) uu___))) uu___) let (check_intro_exists_non_erased : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - unit FStar_Pervasives_Native.option -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + unit FStar_Pervasives_Native.option -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun st -> - fun vprop_typing -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (112)) (Prims.of_int (52)) - (Prims.of_int (112)) (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (110)) (Prims.of_int (46)) - (Prims.of_int (130)) (Prims.of_int (65))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> st.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_IntroExists - { Pulse_Syntax_Base.erased = uu___1; - Pulse_Syntax_Base.p2 = t; - Pulse_Syntax_Base.witnesses = witness::[];_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (114)) - (Prims.of_int (4)) - (Prims.of_int (116)) - (Prims.of_int (26))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (112)) - (Prims.of_int (62)) - (Prims.of_int (130)) - (Prims.of_int (65))))) - (match vprop_typing with - | FStar_Pervasives_Native.Some typing -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Prims.Mkdtuple2 (t, ())))) - | uu___2 -> - Obj.magic - (Obj.repr - (Pulse_Checker_Pure.check_vprop g t))) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 with - | Prims.Mkdtuple2 (t1, t_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (119)) - (Prims.of_int (2)) - (Prims.of_int (120)) - (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (120)) - (Prims.of_int (60)) - (Prims.of_int (130)) - (Prims.of_int (65))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.uu___is_Tm_ExistsSL - t1.Pulse_Syntax_Base.t) - then + fun res_ppname -> + fun st -> + fun vprop_typing -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (125)) (Prims.of_int (10)) + (Prims.of_int (125)) (Prims.of_int (82))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Exists.fst" + (Prims.of_int (125)) (Prims.of_int (85)) + (Prims.of_int (147)) (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g + "check_intro_exists_non_erased" + st.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (127)) + (Prims.of_int (52)) + (Prims.of_int (127)) + (Prims.of_int (59))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (125)) + (Prims.of_int (85)) + (Prims.of_int (147)) + (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> st.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_IntroExists + { Pulse_Syntax_Base.erased = uu___1; + Pulse_Syntax_Base.p2 = t; + Pulse_Syntax_Base.witnesses = + witness::[];_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (129)) + (Prims.of_int (4)) + (Prims.of_int (131)) + (Prims.of_int (26))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (127)) + (Prims.of_int (62)) + (Prims.of_int (147)) + (Prims.of_int (85))))) + (match vprop_typing with + | FStar_Pervasives_Native.Some + typing -> Obj.magic (Obj.repr - (Pulse_Typing_Env.fail - g - FStar_Pervasives_Native.None - "elim_exists argument not a Tm_ExistsSL")) - else + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Prims.Mkdtuple2 + (t, ())))) + | uu___2 -> Obj.magic (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___4 -> ())))) - (fun uu___3 -> - (fun uu___3 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (122)) - (Prims.of_int (26)) - (Prims.of_int (122)) - (Prims.of_int (39))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Exists.fst" - (Prims.of_int (120)) - (Prims.of_int (60)) - (Prims.of_int (130)) - (Prims.of_int (65))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___4 -> - t1.Pulse_Syntax_Base.t)) - (fun uu___4 -> - (fun uu___4 -> - match uu___4 - with - | Pulse_Syntax_Base.Tm_ExistsSL - (u, b, p) - -> - Obj.magic + (Pulse_Checker_Pure.check_vprop + g1 t))) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 with + | Prims.Mkdtuple2 + (t1, t_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (134)) + (Prims.of_int (2)) + (Prims.of_int (137)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (137)) + (Prims.of_int (34)) + (Prims.of_int (147)) + (Prims.of_int (85))))) + (if + Prims.op_Negation + (Pulse_Syntax_Base.uu___is_Tm_ExistsSL + t1.Pulse_Syntax_Base.t) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (136)) + (Prims.of_int (9)) + (Prims.of_int (137)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (135)) + (Prims.of_int (7)) + (Prims.of_int (137)) + (Prims.of_int (33))))) + (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (125)) + (Prims.of_int (137)) + (Prims.of_int (12)) + (Prims.of_int (137)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + t1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Prims.strcat + "check_intro_exists_non_erased: vprop " + (Prims.strcat + uu___3 + " is not an existential"))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + (FStar_Pervasives_Native.Some + (st.Pulse_Syntax_Base.range2)) + uu___3)) + uu___3))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + ())))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (139)) + (Prims.of_int (26)) + (Prims.of_int (139)) + (Prims.of_int (39))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (137)) + (Prims.of_int (34)) + (Prims.of_int (147)) + (Prims.of_int (85))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + t1.Pulse_Syntax_Base.t)) + (fun + uu___4 -> + (fun + uu___4 -> + match uu___4 + with + | + Pulse_Syntax_Base.Tm_ExistsSL + (u, b, p) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Exists.fst" + (Prims.of_int (142)) (Prims.of_int (21)) - (Prims.of_int (125)) + (Prims.of_int (142)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (124)) + (Prims.of_int (141)) (Prims.of_int (47)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> - Pulse_Typing_Metatheory.tm_exists_inversion - g u + Pulse_Typing_Metatheory_Base.tm_exists_inversion + g1 u b.Pulse_Syntax_Base.binder_ty p () (Pulse_Typing_Env.fresh - g))) + g1))) (fun uu___5 -> (fun @@ -972,21 +1266,22 @@ let (check_intro_exists_non_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (127)) + (Prims.of_int (144)) (Prims.of_int (4)) - (Prims.of_int (127)) + (Prims.of_int (144)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (125)) + (Prims.of_int (142)) (Prims.of_int (95)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type - g witness + g1 + witness b.Pulse_Syntax_Base.binder_ty)) (fun uu___7 -> @@ -1005,24 +1300,24 @@ let (check_intro_exists_non_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (128)) + (Prims.of_int (145)) (Prims.of_int (10)) - (Prims.of_int (128)) + (Prims.of_int (145)) (Prims.of_int (77))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (128)) + (Prims.of_int (145)) (Prims.of_int (80)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> Pulse_Typing.T_IntroExists - (g, u, b, - p, + (g1, u, + b, p, witness1, (), (), ()))) @@ -1035,18 +1330,18 @@ let (check_intro_exists_non_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (129)) + (Prims.of_int (146)) (Prims.of_int (45)) - (Prims.of_int (129)) + (Prims.of_int (146)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (128)) + (Prims.of_int (145)) (Prims.of_int (80)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___8 -> @@ -1071,18 +1366,18 @@ let (check_intro_exists_non_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (130)) + (Prims.of_int (147)) (Prims.of_int (2)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (130)) + (Prims.of_int (147)) (Prims.of_int (2)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___9 -> @@ -1097,18 +1392,18 @@ let (check_intro_exists_non_erased : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (130)) - (Prims.of_int (9)) - (Prims.of_int (130)) - (Prims.of_int (37))))) + (Prims.of_int (147)) + (Prims.of_int (18)) + (Prims.of_int (147)) + (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Exists.fst" - (Prims.of_int (130)) + (Prims.of_int (147)) (Prims.of_int (2)) - (Prims.of_int (130)) - (Prims.of_int (65))))) + (Prims.of_int (147)) + (Prims.of_int (85))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -1124,7 +1419,8 @@ let (check_intro_exists_non_erased : Pulse_Syntax_Base.witnesses = [witness1] - })) c d1)) + })) c d1 + res_ppname)) (fun uu___10 -> @@ -1132,7 +1428,7 @@ let (check_intro_exists_non_erased : uu___10 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___10 post_hint @@ -1143,27 +1439,31 @@ let (check_intro_exists_non_erased : uu___8))) uu___7))) uu___5))) - uu___4))) - uu___3))) uu___2))) uu___) + uu___4))) + uu___3))) + uu___2))) uu___))) uu___) let (check_intro_exists : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - unit FStar_Pervasives_Native.option -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + unit FStar_Pervasives_Native.option -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun st -> - fun vprop_typing -> - if is_intro_exists_erased st - then - check_intro_exists_erased g pre () post_hint st vprop_typing - else - check_intro_exists_non_erased g pre () post_hint st - vprop_typing \ No newline at end of file + fun res_ppname -> + fun st -> + fun vprop_typing -> + if is_intro_exists_erased st + then + check_intro_exists_erased g pre () post_hint res_ppname st + vprop_typing + else + check_intro_exists_non_erased g pre () post_hint res_ppname + st vprop_typing \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_If.ml b/src/ocaml/plugin/generated/Pulse_Checker_If.ml index c5a8820fa..2deb14622 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_If.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_If.ml @@ -26,13 +26,13 @@ let rec (combine_if_branches : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (29)) (Prims.of_int (10)) - (Prims.of_int (29)) (Prims.of_int (16))))) + (Prims.of_int (30)) (Prims.of_int (10)) + (Prims.of_int (30)) (Prims.of_int (16))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (30)) (Prims.of_int (2)) - (Prims.of_int (71)) (Prims.of_int (78))))) + (Prims.of_int (31)) (Prims.of_int (2)) + (Prims.of_int (83)) (Prims.of_int (78))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> g_then)) (fun uu___ -> (fun g -> @@ -69,9 +69,117 @@ let rec (combine_if_branches : e_else_typing))) else Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Cannot combine then and else branches (different inames)")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (39)) + (Prims.of_int (11)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (42)) + (Prims.of_int (16)) + (Prims.of_int (42)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames2)) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + ( + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (41)) + (Prims.of_int (16)) + (Prims.of_int (41)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames1)) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + fun x -> + Prims.strcat + (Prims.strcat + "Cannot combine then and else branches (different inames " + (Prims.strcat + uu___4 + " and ")) + (Prims.strcat + x ")"))))) + (fun uu___4 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + uu___4 + uu___3)))) + uu___3))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___3)) uu___3))) | (Pulse_Syntax_Base.C_STGhost (inames1, uu___), Pulse_Syntax_Base.C_STGhost @@ -89,9 +197,117 @@ let rec (combine_if_branches : e_else_typing))) else Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Cannot combine then and else branches (different inames)")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (39)) + (Prims.of_int (11)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (42)) + (Prims.of_int (16)) + (Prims.of_int (42)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames2)) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (40)) + (Prims.of_int (13)) + (Prims.of_int (42)) + (Prims.of_int (43))))) + (Obj.magic + ( + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (41)) + (Prims.of_int (16)) + (Prims.of_int (41)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames1)) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + fun x -> + Prims.strcat + (Prims.strcat + "Cannot combine then and else branches (different inames " + (Prims.strcat + uu___4 + " and ")) + (Prims.strcat + x ")"))))) + (fun uu___4 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + uu___4 + uu___3)))) + uu___3))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___3)) uu___3))) | (Pulse_Syntax_Base.C_ST uu___, Pulse_Syntax_Base.C_STAtomic (inames, uu___1)) -> @@ -114,9 +330,59 @@ let rec (combine_if_branches : c_else))))))) else Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Cannot lift STAtomic else branch to match then")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (52)) + (Prims.of_int (13)) + (Prims.of_int (53)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (51)) + (Prims.of_int (11)) + (Prims.of_int (53)) + (Prims.of_int (42))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (53)) + (Prims.of_int (16)) + (Prims.of_int (53)) + (Prims.of_int (41))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames)) + (fun uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___4 -> + Prims.strcat + "Cannot lift STAtomic else branch to match ST then branch, inames " + (Prims.strcat + uu___3 + " not empty"))))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___3)) uu___3))) | (Pulse_Syntax_Base.C_STAtomic (inames, uu___), Pulse_Syntax_Base.C_ST uu___1) -> @@ -140,9 +406,59 @@ let rec (combine_if_branches : e_else_typing))) else Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "Cannot lift STAtomic else branch to match then")) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (63)) + (Prims.of_int (13)) + (Prims.of_int (64)) + (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (62)) + (Prims.of_int (11)) + (Prims.of_int (64)) + (Prims.of_int (42))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (64)) + (Prims.of_int (16)) + (Prims.of_int (64)) + (Prims.of_int (41))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + inames)) + (fun uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___4 -> + Prims.strcat + "Cannot lift STAtomic then branch to match ST else branch, inames " + (Prims.strcat + uu___3 + " not empty"))))) + (fun uu___3 -> + (fun uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail + g + FStar_Pervasives_Native.None + uu___3)) uu___3))) | (Pulse_Syntax_Base.C_STGhost (uu___, uu___1), uu___2) -> Obj.repr @@ -151,17 +467,17 @@ let rec (combine_if_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (58)) + (Prims.of_int (66)) (Prims.of_int (14)) - (Prims.of_int (58)) + (Prims.of_int (66)) (Prims.of_int (82))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (58)) + (Prims.of_int (66)) (Prims.of_int (85)) - (Prims.of_int (63)) + (Prims.of_int (71)) (Prims.of_int (35))))) (Obj.magic (Pulse_Checker_Pure.get_non_informative_witness @@ -178,17 +494,17 @@ let rec (combine_if_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (60)) + (Prims.of_int (68)) (Prims.of_int (8)) - (Prims.of_int (60)) + (Prims.of_int (68)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (60)) + (Prims.of_int (68)) (Prims.of_int (69)) - (Prims.of_int (63)) + (Prims.of_int (71)) (Prims.of_int (35))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -216,18 +532,18 @@ let rec (combine_if_branches : Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (62)) + (Prims.of_int (70)) (Prims.of_int (8)) - (Prims.of_int (62)) + (Prims.of_int (70)) (Prims.of_int (67))))) (FStar_Sealed.seal ( Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (60)) + (Prims.of_int (68)) (Prims.of_int (69)) - (Prims.of_int (63)) + (Prims.of_int (71)) (Prims.of_int (35))))) (Obj.magic ( @@ -270,17 +586,17 @@ let rec (combine_if_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (65)) + (Prims.of_int (73)) (Prims.of_int (14)) - (Prims.of_int (65)) + (Prims.of_int (73)) (Prims.of_int (82))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (65)) + (Prims.of_int (73)) (Prims.of_int (85)) - (Prims.of_int (68)) + (Prims.of_int (76)) (Prims.of_int (65))))) (Obj.magic (Pulse_Checker_Pure.get_non_informative_witness @@ -297,17 +613,17 @@ let rec (combine_if_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (67)) + (Prims.of_int (75)) (Prims.of_int (8)) - (Prims.of_int (67)) + (Prims.of_int (75)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (68)) + (Prims.of_int (76)) (Prims.of_int (6)) - (Prims.of_int (68)) + (Prims.of_int (76)) (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -347,7 +663,17 @@ let rec (combine_if_branches : Obj.repr (Pulse_Typing_Env.fail g FStar_Pervasives_Native.None - "Cannot combine then and else branches (incompatible effects)"))) + (Prims.strcat + (Prims.strcat + "Cannot combine then and else branches (incompatible effects " + (Prims.strcat + (Pulse_Syntax_Printer.ctag_to_string + (Pulse_Syntax_Base.ctag_of_comp_st + c_then)) " and ")) + (Prims.strcat + (Pulse_Syntax_Printer.ctag_to_string + (Pulse_Syntax_Base.ctag_of_comp_st + c_else)) " resp.)"))))) else Obj.magic (Obj.repr @@ -360,158 +686,191 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_for_env -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.st_term -> + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.term -> Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun b -> - fun e1 -> - fun e2 -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (86)) (Prims.of_int (4)) - (Prims.of_int (86)) (Prims.of_int (45))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (83)) (Prims.of_int (53)) - (Prims.of_int (135)) (Prims.of_int (32))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_with_expected_type g b - Pulse_Typing.tm_bool)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Prims.Mkdtuple2 (b1, b_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (88)) - (Prims.of_int (13)) - (Prims.of_int (88)) - (Prims.of_int (27))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (88)) - (Prims.of_int (30)) - (Prims.of_int (135)) - (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - post_hint.Pulse_Typing.post)) - (fun uu___1 -> - (fun post -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (89)) - (Prims.of_int (12)) - (Prims.of_int (89)) - (Prims.of_int (19))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (89)) - (Prims.of_int (22)) - (Prims.of_int (135)) - (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Typing_Env.fresh g)) - (fun uu___1 -> - (fun hyp -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (91)) - (Prims.of_int (4)) - (Prims.of_int (91)) - (Prims.of_int (64))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.If.fst" - (Prims.of_int (92)) - (Prims.of_int (4)) - (Prims.of_int (135)) - (Prims.of_int (32))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - fun eq_v -> - Pulse_Typing_Env.push_binding - g hyp - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_eq2 + fun res_ppname -> + fun b -> + fun e1 -> + fun e2 -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.If.fst" + (Prims.of_int (98)) (Prims.of_int (10)) + (Prims.of_int (98)) (Prims.of_int (61))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.If.fst" + (Prims.of_int (98)) (Prims.of_int (64)) + (Prims.of_int (160)) (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_if" + e1.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (101)) + (Prims.of_int (4)) + (Prims.of_int (101)) + (Prims.of_int (45))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (98)) + (Prims.of_int (64)) + (Prims.of_int (160)) + (Prims.of_int (43))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_with_expected_type + g1 b Pulse_Typing.tm_bool)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Prims.Mkdtuple2 (b1, b_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (103)) + (Prims.of_int (13)) + (Prims.of_int (103)) + (Prims.of_int (27))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (103)) + (Prims.of_int (30)) + (Prims.of_int (160)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + post_hint.Pulse_Typing.post)) + (fun uu___1 -> + (fun post -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (104)) + (Prims.of_int (12)) + (Prims.of_int (104)) + (Prims.of_int (19))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (104)) + (Prims.of_int (22)) + (Prims.of_int (160)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Typing_Env.fresh + g1)) + (fun uu___1 -> + (fun hyp -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (106)) + (Prims.of_int (4)) + (Prims.of_int (106)) + (Prims.of_int (80))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (107)) + (Prims.of_int (4)) + (Prims.of_int (160)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___1 -> + fun eq_v + -> + Pulse_Typing_Env.push_binding + g1 hyp + (Pulse_Syntax_Base.mk_ppname_no_range + "_if_hyp") + (Pulse_Typing.mk_eq2 Pulse_Syntax_Pure.u0 Pulse_Typing.tm_bool b1 eq_v))) - (fun uu___1 -> - (fun g_with_eq -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - ( - FStar_Sealed.seal + (fun + uu___1 -> + (fun + g_with_eq + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (97)) + (Prims.of_int (112)) (Prims.of_int (47)) - (Prims.of_int (111)) + (Prims.of_int (132)) (Prims.of_int (23))))) - ( - FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (112)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (135)) - (Prims.of_int (32))))) - ( - FStar_Tactics_Effect.lift_div_tac + (Prims.of_int (160)) + (Prims.of_int (43))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> fun eq_v -> fun br -> + fun + is_then + -> FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (98)) + (Prims.of_int (113)) (Prims.of_int (20)) - (Prims.of_int (98)) + (Prims.of_int (113)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (98)) + (Prims.of_int (113)) (Prims.of_int (37)) - (Prims.of_int (111)) + (Prims.of_int (132)) (Prims.of_int (23))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -529,17 +888,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (100)) + (Prims.of_int (115)) (Prims.of_int (6)) - (Prims.of_int (102)) - (Prims.of_int (48))))) + (Prims.of_int (118)) + (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (103)) + (Prims.of_int (119)) (Prims.of_int (6)) - (Prims.of_int (111)) + (Prims.of_int (132)) (Prims.of_int (23))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -556,52 +915,81 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (104)) - (Prims.of_int (12)) - (Prims.of_int (104)) - (Prims.of_int (62))))) + (Prims.of_int (121)) + (Prims.of_int (24)) + (Prims.of_int (125)) + (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (104)) - (Prims.of_int (65)) - (Prims.of_int (111)) + (Prims.of_int (119)) + (Prims.of_int (6)) + (Prims.of_int (132)) (Prims.of_int (23))))) (Obj.magic - (check1 - g_with_eq1 - pre () - (FStar_Pervasives_Native.Some - post_hint) - br)) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (122)) + (Prims.of_int (19)) + (Prims.of_int (122)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (122)) + (Prims.of_int (49)) + (Prims.of_int (125)) + (Prims.of_int (37))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> - (fun r -> + Pulse_Syntax_Base.mk_ppname_no_range + "_if_br")) + (fun + uu___2 -> + (fun + ppname -> Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (105)) - (Prims.of_int (25)) - (Prims.of_int (105)) - (Prims.of_int (49))))) + (Prims.of_int (124)) + (Prims.of_int (8)) + (Prims.of_int (124)) + (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (104)) - (Prims.of_int (65)) - (Prims.of_int (111)) - (Prims.of_int (23))))) + (Prims.of_int (125)) + (Prims.of_int (6)) + (Prims.of_int (125)) + (Prims.of_int (37))))) (Obj.magic + (check1 + g_with_eq1 + pre () + (FStar_Pervasives_Native.Some + post_hint) + ppname br)) + (fun + uu___2 -> + (fun r -> + Obj.magic (Pulse_Checker_Base.apply_checker_result_k g_with_eq1 pre post_hint - r)) + r ppname)) + uu___2))) + uu___2))) (fun uu___2 -> (fun @@ -612,6 +1000,38 @@ let (check : FStar_Pervasives.Mkdtuple3 (br1, c, d) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (127)) + (Prims.of_int (18)) + (Prims.of_int (127)) + (Prims.of_int (52))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (129)) + (Prims.of_int (4)) + (Prims.of_int (132)) + (Prims.of_int (23))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + if + is_then + then + "then" + else + "else")) + (fun + uu___3 -> + (fun + br_name + -> if FStar_Set.mem hyp @@ -621,38 +1041,28 @@ let (check : Obj.magic (Obj.repr (Pulse_Typing_Env.fail - g + g1 (FStar_Pervasives_Native.Some (br1.Pulse_Syntax_Base.range2)) - "Illegal use of control-flow hypothesis in branch")) + (Prims.strcat + "check_if: branch hypothesis is in freevars of checked " + (Prims.strcat + br_name + " branch")))) else Obj.magic (Obj.repr - (if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c) - then - Obj.repr - (Pulse_Typing_Env.fail - g - (FStar_Pervasives_Native.Some - (br1.Pulse_Syntax_Base.range2)) - "Branch computation type not st") - else - Obj.repr (FStar_Tactics_Effect.lift_div_tac (fun - uu___5 -> + uu___4 -> FStar_Pervasives.Mkdtuple3 (br1, c, - d)))))) - uu___2))) + d))))) + uu___3))) uu___2))) uu___2))) uu___2))) - ( - fun + (fun uu___1 -> (fun check_branch @@ -663,22 +1073,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (114)) + (Prims.of_int (135)) (Prims.of_int (32)) - (Prims.of_int (114)) - (Prims.of_int (55))))) + (Prims.of_int (135)) + (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (112)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (135)) - (Prims.of_int (32))))) + (Prims.of_int (160)) + (Prims.of_int (43))))) (Obj.magic (check_branch Pulse_Typing.tm_true - e1)) + e1 true)) (fun uu___1 -> (fun @@ -696,22 +1106,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (115)) + (Prims.of_int (136)) (Prims.of_int (32)) - (Prims.of_int (115)) - (Prims.of_int (56))))) + (Prims.of_int (136)) + (Prims.of_int (62))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (114)) - (Prims.of_int (58)) (Prims.of_int (135)) - (Prims.of_int (32))))) + (Prims.of_int (63)) + (Prims.of_int (160)) + (Prims.of_int (43))))) (Obj.magic (check_branch Pulse_Typing.tm_false - e2)) + e2 false)) (fun uu___2 -> (fun @@ -729,18 +1139,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (117)) + (Prims.of_int (138)) (Prims.of_int (4)) - (Prims.of_int (117)) + (Prims.of_int (138)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (115)) - (Prims.of_int (59)) - (Prims.of_int (135)) - (Prims.of_int (32))))) + (Prims.of_int (136)) + (Prims.of_int (65)) + (Prims.of_int (160)) + (Prims.of_int (43))))) (Obj.magic (combine_if_branches (g_with_eq @@ -769,41 +1179,41 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (119)) + (Prims.of_int (140)) (Prims.of_int (16)) - (Prims.of_int (129)) + (Prims.of_int (154)) (Prims.of_int (88))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (130)) + (Prims.of_int (155)) (Prims.of_int (4)) - (Prims.of_int (135)) - (Prims.of_int (32))))) + (Prims.of_int (160)) + (Prims.of_int (43))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (120)) + (Prims.of_int (141)) (Prims.of_int (12)) - (Prims.of_int (120)) + (Prims.of_int (141)) (Prims.of_int (19))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (121)) + (Prims.of_int (142)) (Prims.of_int (4)) - (Prims.of_int (129)) + (Prims.of_int (154)) (Prims.of_int (88))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> Pulse_Typing_Env.fresh - g)) + g1)) (fun uu___4 -> (fun x -> @@ -815,9 +1225,9 @@ let (check : then Obj.magic (Pulse_Typing_Env.fail - g + g1 FStar_Pervasives_Native.None - "Unexpected name clash") + "Impossible: check_if: unexpected freevar in post, please file a bug-report") else if Prims.op_Negation @@ -837,10 +1247,267 @@ let (check : post_hint.Pulse_Typing.post)) then Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (147)) + (Prims.of_int (9)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (151)) + (Prims.of_int (81)) + (Prims.of_int (151)) + (Prims.of_int (114))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + post_hint.Pulse_Typing.post)) + (fun + uu___5 -> + (fun + uu___5 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (151)) + (Prims.of_int (45)) + (Prims.of_int (151)) + (Prims.of_int (80))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + post_hint.Pulse_Typing.ret_ty)) + (fun + uu___6 -> + (fun + uu___6 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (150)) + (Prims.of_int (76)) + (Prims.of_int (150)) + (Prims.of_int (108))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + (Pulse_Syntax_Base.comp_post + c))) + (fun + uu___7 -> + (fun + uu___7 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (148)) + (Prims.of_int (11)) + (Prims.of_int (151)) + (Prims.of_int (115))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.If.fst" + (Prims.of_int (150)) + (Prims.of_int (44)) + (Prims.of_int (150)) + (Prims.of_int (75))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + (Pulse_Syntax_Base.comp_res + c))) + (fun + uu___8 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___9 -> + fun x1 -> + fun x2 -> + fun x3 -> + fun x4 -> + Prims.strcat + (Prims.strcat + (Prims.strcat + (Prims.strcat + (Prims.strcat + (Prims.strcat + "check_if: computation type after combining branches does not match post hint,computed: (" + (Prims.strcat + (Pulse_Syntax_Printer.univ_to_string + (Pulse_Syntax_Base.comp_u + c)) ", ")) + (Prims.strcat + uu___8 + ", ")) + (Prims.strcat + x1 + "), expected (")) + (Prims.strcat + x2 ", ")) + (Prims.strcat + x3 ", ")) + (Prims.strcat + x4 ")"))))) + (fun + uu___8 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___9 -> + uu___8 + uu___7)))) + uu___7))) + (fun + uu___7 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___8 -> + uu___7 + (Pulse_Syntax_Printer.univ_to_string + post_hint.Pulse_Typing.u))))) + (fun + uu___7 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___8 -> + uu___7 + uu___6)))) + uu___6))) + (fun + uu___6 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___7 -> + uu___6 + uu___5)))) + uu___5))) + (fun + uu___5 -> + (fun + uu___5 -> + Obj.magic (Pulse_Typing_Env.fail - g + g1 FStar_Pervasives_Native.None - "Unexpected result type in branches") + uu___5)) + uu___5)) else Obj.magic (FStar_Tactics_Effect.tac_bind @@ -848,23 +1515,23 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (128)) + (Prims.of_int (153)) (Prims.of_int (26)) - (Prims.of_int (128)) + (Prims.of_int (153)) (Prims.of_int (56))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (129)) + (Prims.of_int (154)) (Prims.of_int (8)) - (Prims.of_int (129)) + (Prims.of_int (154)) (Prims.of_int (88))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> Pulse_Typing.post_hint_typing - g + g1 post_hint x)) (fun @@ -874,8 +1541,8 @@ let (check : -> Obj.magic (Pulse_Checker_Base.intro_comp_typing - g c () () - x ())) + g1 c () + () x ())) uu___6))) uu___4))) (fun @@ -889,18 +1556,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (133)) + (Prims.of_int (158)) (Prims.of_int (4)) - (Prims.of_int (133)) + (Prims.of_int (158)) (Prims.of_int (84))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.If.fst" - (Prims.of_int (135)) + (Prims.of_int (160)) (Prims.of_int (2)) - (Prims.of_int (135)) - (Prims.of_int (32))))) + (Prims.of_int (160)) + (Prims.of_int (43))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -919,7 +1586,7 @@ let (check : FStar_Pervasives_Native.None })), c, (Pulse_Typing.T_If - (g, b1, + (g1, b1, e11, e21, c, (Pulse_Syntax_Base.comp_u @@ -933,15 +1600,17 @@ let (check : (fun d -> Obj.magic (Pulse_Checker_Base.checker_result_for_st_typing - g pre + g1 pre (FStar_Pervasives_Native.Some post_hint) - d)) + d + res_ppname)) uu___4))) uu___4))) uu___3))) uu___2))) uu___1))) uu___1))) - uu___1))) - uu___1))) uu___1))) uu___) \ No newline at end of file + uu___1))) + uu___1))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_IntroPure.ml b/src/ocaml/plugin/generated/Pulse_Checker_IntroPure.ml index 40c31fc9a..feab46013 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_IntroPure.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_IntroPure.ml @@ -11,31 +11,157 @@ let (check_prop : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (13)) (Prims.of_int (26)) (Prims.of_int (13)) - (Prims.of_int (70))))) + (Prims.of_int (14)) (Prims.of_int (11)) (Prims.of_int (14)) + (Prims.of_int (12))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (11)) (Prims.of_int (45)) (Prims.of_int (18)) - (Prims.of_int (38))))) - (Obj.magic - (Pulse_Checker_Pure.check_vprop g (Pulse_Syntax_Base.tm_pure p))) + (Prims.of_int (14)) (Prims.of_int (15)) (Prims.of_int (25)) + (Prims.of_int (30))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> p)) (fun uu___ -> - (fun uu___ -> - match uu___ with - | Prims.Mkdtuple2 (p1, p_typing) -> - (match p1.Pulse_Syntax_Base.t with - | Pulse_Syntax_Base.Tm_Pure pp -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> Prims.Mkdtuple2 (pp, ())))) - | uu___1 -> - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None "Unexpected prop")))) - uu___) + (fun p0 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" + (Prims.of_int (15)) (Prims.of_int (26)) + (Prims.of_int (15)) (Prims.of_int (70))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" + (Prims.of_int (14)) (Prims.of_int (15)) + (Prims.of_int (25)) (Prims.of_int (30))))) + (Obj.magic + (Pulse_Checker_Pure.check_vprop g + (Pulse_Syntax_Base.tm_pure p))) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Prims.Mkdtuple2 (p1, p_typing) -> + (match p1.Pulse_Syntax_Base.t with + | Pulse_Syntax_Base.Tm_Pure pp -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Prims.Mkdtuple2 (pp, ())))) + | uu___1 -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (22)) + (Prims.of_int (6)) + (Prims.of_int (25)) + (Prims.of_int (30))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (21)) + (Prims.of_int (4)) + (Prims.of_int (25)) + (Prims.of_int (30))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (25)) + (Prims.of_int (9)) + (Prims.of_int (25)) + (Prims.of_int (29))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (22)) + (Prims.of_int (6)) + (Prims.of_int (25)) + (Prims.of_int (30))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + p1)) + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (22)) + (Prims.of_int (6)) + (Prims.of_int (25)) + (Prims.of_int (30))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (22)) + (Prims.of_int (6)) + (Prims.of_int (25)) + (Prims.of_int (30))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (24)) + (Prims.of_int (9)) + (Prims.of_int (24)) + (Prims.of_int (40))))) + (FStar_Sealed.seal + ( + Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + ( + Pulse_Syntax_Printer.term_to_string + (Pulse_Syntax_Base.tm_pure + p0))) + (fun uu___3 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + fun x -> + Prims.strcat + (Prims.strcat + "Impossible: check_intro_pure: checking a pure vprop " + (Prims.strcat + uu___3 + " returned a non-pure vprop ")) + (Prims.strcat + x + ",please file a bug-report"))))) + (fun uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___4 + -> + uu___3 + uu___2)))) + uu___2))) + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (Pulse_Typing_Env.fail g + FStar_Pervasives_Native.None + uu___2)) uu___2))))) + uu___))) uu___) let (check_prop_validity : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> @@ -50,118 +176,154 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (32)) (Prims.of_int (27)) - (Prims.of_int (32)) (Prims.of_int (33))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (30)) (Prims.of_int (46)) - (Prims.of_int (36)) (Prims.of_int (63))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_IntroPure - { Pulse_Syntax_Base.p = p;_} -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (33)) (Prims.of_int (26)) - (Prims.of_int (33)) (Prims.of_int (40))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (32)) (Prims.of_int (36)) - (Prims.of_int (36)) (Prims.of_int (63))))) - (Obj.magic (check_prop g p)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 (p1, p_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (34)) - (Prims.of_int (11)) - (Prims.of_int (34)) - (Prims.of_int (43))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (34)) - (Prims.of_int (46)) - (Prims.of_int (36)) - (Prims.of_int (63))))) - (Obj.magic - (check_prop_validity g p1 ())) - (fun uu___2 -> - (fun pv -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (35)) - (Prims.of_int (18)) - (Prims.of_int (35)) - (Prims.of_int (45))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.IntroPure.fst" - (Prims.of_int (36)) - (Prims.of_int (2)) - (Prims.of_int (36)) - (Prims.of_int (63))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - Pulse_Typing.T_IntroPure - (g, p1, (), - pv))) - (fun uu___2 -> - (fun st_typing -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" + (Prims.of_int (40)) (Prims.of_int (10)) + (Prims.of_int (40)) (Prims.of_int (68))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" + (Prims.of_int (40)) (Prims.of_int (71)) + (Prims.of_int (46)) (Prims.of_int (83))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "check_intro_pure" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (42)) (Prims.of_int (27)) + (Prims.of_int (42)) (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (40)) (Prims.of_int (71)) + (Prims.of_int (46)) (Prims.of_int (83))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_IntroPure + { Pulse_Syntax_Base.p = p;_} -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (43)) + (Prims.of_int (26)) + (Prims.of_int (43)) + (Prims.of_int (40))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (42)) + (Prims.of_int (36)) + (Prims.of_int (46)) + (Prims.of_int (83))))) + (Obj.magic (check_prop g1 p)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 + (p1, p_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (44)) + (Prims.of_int (11)) + (Prims.of_int (44)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (44)) + (Prims.of_int (46)) + (Prims.of_int (46)) + (Prims.of_int (83))))) + (Obj.magic + (check_prop_validity + g1 p1 ())) + (fun uu___2 -> + (fun pv -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (36)) - (Prims.of_int (9)) - (Prims.of_int (36)) + (Prims.of_int (45)) + (Prims.of_int (18)) + (Prims.of_int (45)) (Prims.of_int (45))))) - (FStar_Sealed.seal + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.IntroPure.fst" - (Prims.of_int (36)) + (Prims.of_int (46)) (Prims.of_int (2)) - (Prims.of_int (36)) - (Prims.of_int (63))))) - (Obj.magic + (Prims.of_int (46)) + (Prims.of_int (83))))) + ( + FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Pulse_Typing.T_IntroPure + (g1, p1, + (), pv))) + ( + fun + uu___2 -> + (fun + st_typing + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (46)) + (Prims.of_int (18)) + (Prims.of_int (46)) + (Prims.of_int (65))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.IntroPure.fst" + (Prims.of_int (46)) + (Prims.of_int (2)) + (Prims.of_int (46)) + (Prims.of_int (83))))) + (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () (Pulse_Typing.wr @@ -172,17 +334,19 @@ let (check : })) (Pulse_Typing.comp_intro_pure p1) - st_typing)) - (fun uu___2 - -> + st_typing + res_ppname)) + (fun + uu___2 -> (fun uu___2 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___2 post_hint t.Pulse_Syntax_Base.range2)) uu___2))) - uu___2))) uu___2))) - uu___1))) uu___) \ No newline at end of file + uu___2))) + uu___2))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Match.ml b/src/ocaml/plugin/generated/Pulse_Checker_Match.ml index 589e83ace..ce9f2e8bc 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Match.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Match.ml @@ -413,7 +413,7 @@ let (check_branch : (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (218)) (Prims.of_int (27)) - (Prims.of_int (242)) (Prims.of_int (58))))) + (Prims.of_int (241)) (Prims.of_int (58))))) (match readback_pat p0 with | FStar_Pervasives_Native.Some p -> Obj.magic @@ -445,7 +445,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (221)) (Prims.of_int (54)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -469,7 +469,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (222)) (Prims.of_int (38)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -493,7 +493,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (223)) (Prims.of_int (27)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -517,7 +517,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (225)) (Prims.of_int (2)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -544,7 +544,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (227)) (Prims.of_int (2)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (if Prims.op_Negation @@ -585,7 +585,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (228)) (Prims.of_int (80)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (if FStar_Reflection_V2_Data.uu___is_Tv_Unknown @@ -628,7 +628,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (230)) (Prims.of_int (89)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -661,7 +661,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (231)) (Prims.of_int (109)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -698,7 +698,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (232)) (Prims.of_int (39)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (Obj.magic (open_st_term_bs @@ -724,7 +724,7 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (233)) (Prims.of_int (64)) - (Prims.of_int (242)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -744,14 +744,14 @@ let (check_branch : (Prims.of_int (234)) (Prims.of_int (19)) (Prims.of_int (234)) - (Prims.of_int (90))))) + (Prims.of_int (96))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (234)) - (Prims.of_int (93)) - (Prims.of_int (242)) + (Prims.of_int (99)) + (Prims.of_int (241)) (Prims.of_int (58))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -770,15 +770,15 @@ let (check_branch : "Pulse.Checker.Match.fst" (Prims.of_int (236)) (Prims.of_int (23)) - (Prims.of_int (238)) - (Prims.of_int (28))))) + (Prims.of_int (239)) + (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (234)) - (Prims.of_int (93)) - (Prims.of_int (242)) + (Prims.of_int (99)) + (Prims.of_int (241)) (Prims.of_int (58))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -787,24 +787,51 @@ let (check_branch : (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (237)) - (Prims.of_int (12)) + (Prims.of_int (17)) (Prims.of_int (237)) - (Prims.of_int (54))))) + (Prims.of_int (41))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (237)) + (Prims.of_int (44)) + (Prims.of_int (239)) + (Prims.of_int (35))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_br")) + (fun + uu___2 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (238)) - (Prims.of_int (4)) + (Prims.of_int (12)) (Prims.of_int (238)) - (Prims.of_int (28))))) + (Prims.of_int (61))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (239)) + (Prims.of_int (4)) + (Prims.of_int (239)) + (Prims.of_int (35))))) (Obj.magic (check g'1 pre () (FStar_Pervasives_Native.Some post_hint) - e1)) + ppname e1)) (fun uu___2 -> (fun r -> @@ -812,60 +839,20 @@ let (check_branch : (Pulse_Checker_Base.apply_checker_result_k g'1 pre post_hint - r)) + r ppname)) + uu___2))) uu___2))) (fun uu___2 -> + FStar_Tactics_Effect.lift_div_tac (fun - uu___2 -> + uu___3 -> match uu___2 with | FStar_Pervasives.Mkdtuple3 (e2, c, e_d) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (239)) - (Prims.of_int (2)) - (Prims.of_int (240)) - (Prims.of_int (62))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (242)) - (Prims.of_int (2)) - (Prims.of_int (242)) - (Prims.of_int (58))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.stateful_comp - c) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g - (FStar_Pervasives_Native.Some - (e2.Pulse_Syntax_Base.range2)) - "Branch computation is not stateful")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun - uu___4 -> - ())))) - (fun - uu___3 -> - FStar_Tactics_Effect.lift_div_tac - (fun - uu___4 -> FStar_Pervasives.Mkdtuple4 (p, (Pulse_Syntax_Naming.close_st_term_n @@ -888,7 +875,6 @@ let (check_branch : uu___2))) uu___2))) uu___2))) - uu___2))) uu___1))) uu___))) uu___))) @@ -928,13 +914,13 @@ let (check_branches : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (258)) (Prims.of_int (2)) - (Prims.of_int (258)) (Prims.of_int (50))))) + (Prims.of_int (257)) (Prims.of_int (2)) + (Prims.of_int (257)) (Prims.of_int (50))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (258)) (Prims.of_int (51)) - (Prims.of_int (291)) (Prims.of_int (18))))) + (Prims.of_int (257)) (Prims.of_int (51)) + (Prims.of_int (290)) (Prims.of_int (18))))) (if FStar_List_Tot_Base.isEmpty brs0 then Obj.magic @@ -954,17 +940,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (259)) + (Prims.of_int (258)) (Prims.of_int (22)) - (Prims.of_int (259)) + (Prims.of_int (258)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (258)) + (Prims.of_int (257)) (Prims.of_int (51)) - (Prims.of_int (291)) + (Prims.of_int (290)) (Prims.of_int (18))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> brs0)) @@ -978,17 +964,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (260)) + (Prims.of_int (259)) (Prims.of_int (26)) - (Prims.of_int (260)) + (Prims.of_int (259)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (259)) + (Prims.of_int (258)) (Prims.of_int (29)) - (Prims.of_int (291)) + (Prims.of_int (290)) (Prims.of_int (18))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> bnds)) @@ -1004,18 +990,18 @@ let (check_branches : Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (261)) + (Prims.of_int (260)) (Prims.of_int (29)) - (Prims.of_int (261)) + (Prims.of_int (260)) (Prims.of_int (100))))) (FStar_Sealed.seal ( Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (260)) + (Prims.of_int (259)) (Prims.of_int (33)) - (Prims.of_int (291)) + (Prims.of_int (290)) (Prims.of_int (18))))) (Obj.magic ( @@ -1044,17 +1030,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (264)) + (Prims.of_int (263)) (Prims.of_int (3)) - (Prims.of_int (276)) + (Prims.of_int (275)) (Prims.of_int (5))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (291)) + (Prims.of_int (290)) (Prims.of_int (2)) - (Prims.of_int (291)) + (Prims.of_int (290)) (Prims.of_int (18))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1062,17 +1048,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (267)) + (Prims.of_int (266)) (Prims.of_int (5)) - (Prims.of_int (272)) + (Prims.of_int (271)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (273)) + (Prims.of_int (272)) (Prims.of_int (6)) - (Prims.of_int (276)) + (Prims.of_int (275)) (Prims.of_int (5))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1085,17 +1071,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (268)) + (Prims.of_int (267)) (Prims.of_int (19)) - (Prims.of_int (268)) + (Prims.of_int (267)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (267)) + (Prims.of_int (266)) (Prims.of_int (5)) - (Prims.of_int (272)) + (Prims.of_int (271)) (Prims.of_int (20))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1116,17 +1102,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (269)) + (Prims.of_int (268)) (Prims.of_int (20)) - (Prims.of_int (269)) + (Prims.of_int (268)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (268)) + (Prims.of_int (267)) (Prims.of_int (23)) - (Prims.of_int (272)) + (Prims.of_int (271)) (Prims.of_int (20))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1147,17 +1133,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (270)) + (Prims.of_int (269)) (Prims.of_int (29)) - (Prims.of_int (270)) + (Prims.of_int (269)) (Prims.of_int (95))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (269)) + (Prims.of_int (268)) (Prims.of_int (26)) - (Prims.of_int (272)) + (Prims.of_int (271)) (Prims.of_int (20))))) (Obj.magic (check_branch @@ -1194,17 +1180,17 @@ let (check_branches : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (274)) + (Prims.of_int (273)) (Prims.of_int (12)) - (Prims.of_int (274)) + (Prims.of_int (273)) (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (274)) + (Prims.of_int (273)) (Prims.of_int (8)) - (Prims.of_int (274)) + (Prims.of_int (273)) (Prims.of_int (9))))) (Obj.magic (Pulse_Common.zipWith @@ -1256,128 +1242,159 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_for_env -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.branch Prims.list -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.term -> + Pulse_Syntax_Base.branch Prims.list -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun sc -> - fun brs -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (303)) (Prims.of_int (17)) - (Prims.of_int (303)) (Prims.of_int (25))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (303)) (Prims.of_int (28)) - (Prims.of_int (349)) (Prims.of_int (44))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> sc.Pulse_Syntax_Base.range1)) - (fun uu___ -> - (fun sc_range -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (304)) - (Prims.of_int (17)) - (Prims.of_int (304)) - (Prims.of_int (20))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (304)) - (Prims.of_int (23)) - (Prims.of_int (349)) - (Prims.of_int (44))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> brs)) - (fun uu___ -> - (fun orig_brs -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (305)) - (Prims.of_int (12)) - (Prims.of_int (305)) - (Prims.of_int (24))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (305)) - (Prims.of_int (27)) - (Prims.of_int (349)) - (Prims.of_int (44))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - FStar_List_Tot_Base.length brs)) - (fun uu___ -> - (fun nbr -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (307)) - (Prims.of_int (55)) - (Prims.of_int (307)) - (Prims.of_int (79))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Match.fst" - (Prims.of_int (305)) - (Prims.of_int (27)) - (Prims.of_int (349)) - (Prims.of_int (44))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_and_type - g sc)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple5 - (sc1, sc_u, - sc_ty, - sc_ty_typing, - sc_typing) - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic + fun res_ppname -> + fun sc -> + fun brs -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Match.fst" + (Prims.of_int (304)) (Prims.of_int (10)) + (Prims.of_int (304)) (Prims.of_int (64))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Match.fst" + (Prims.of_int (304)) (Prims.of_int (67)) + (Prims.of_int (352)) (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context_no_range g + "check_match")) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (306)) + (Prims.of_int (17)) + (Prims.of_int (306)) + (Prims.of_int (25))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (306)) + (Prims.of_int (28)) + (Prims.of_int (352)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> sc.Pulse_Syntax_Base.range1)) + (fun uu___ -> + (fun sc_range -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (307)) + (Prims.of_int (17)) + (Prims.of_int (307)) + (Prims.of_int (20))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (307)) + (Prims.of_int (23)) + (Prims.of_int (352)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> brs)) + (fun uu___ -> + (fun orig_brs -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (308)) + (Prims.of_int (12)) + (Prims.of_int (308)) + (Prims.of_int (24))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (308)) + (Prims.of_int (27)) + (Prims.of_int (352)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + FStar_List_Tot_Base.length + brs)) + (fun uu___ -> + (fun nbr -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (310)) + (Prims.of_int (55)) + (Prims.of_int (310)) + (Prims.of_int (79))))) + (FStar_Sealed.seal + (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" (Prims.of_int (308)) + (Prims.of_int (27)) + (Prims.of_int (352)) + (Prims.of_int (55))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_and_type + g1 sc)) + (fun uu___ -> + (fun uu___ + -> + match uu___ + with + | + FStar_Pervasives.Mkdtuple5 + (sc1, + sc_u, + sc_ty, + sc_ty_typing, + sc_typing) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Match.fst" + (Prims.of_int (311)) (Prims.of_int (18)) - (Prims.of_int (308)) + (Prims.of_int (311)) (Prims.of_int (48))))) - (FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (313)) + (Prims.of_int (316)) (Prims.of_int (4)) - (Prims.of_int (349)) - (Prims.of_int (44))))) - (FStar_Tactics_Effect.lift_div_tac + (Prims.of_int (352)) + (Prims.of_int (55))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> FStar_List_Tot_Base.map @@ -1385,8 +1402,8 @@ let (check : (FStar_List_Tot_Base.map FStar_Pervasives_Native.fst brs))) - (fun uu___1 - -> + (fun + uu___1 -> (fun elab_pats -> @@ -1396,40 +1413,40 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (320)) - (Prims.of_int (4)) (Prims.of_int (323)) + (Prims.of_int (4)) + (Prims.of_int (326)) (Prims.of_int (75))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (313)) + (Prims.of_int (316)) (Prims.of_int (4)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (320)) + (Prims.of_int (323)) (Prims.of_int (10)) - (Prims.of_int (320)) + (Prims.of_int (323)) (Prims.of_int (88))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (320)) - (Prims.of_int (4)) (Prims.of_int (323)) + (Prims.of_int (4)) + (Prims.of_int (326)) (Prims.of_int (75))))) (Obj.magic (FStar_Tactics_V2_Builtins.check_match_complete (Pulse_Typing.elab_env - g) + g1) (Pulse_Elaborate_Pure.elab_term sc1) (Pulse_Elaborate_Pure.elab_term @@ -1447,7 +1464,7 @@ let (check : Obj.magic (Obj.repr (Pulse_Typing_Env.fail - g + g1 (FStar_Pervasives_Native.Some sc_range) "Could not check that match is correct/complete")) @@ -1464,13 +1481,13 @@ let (check : (elab_pats', bnds, (Pulse_Typing.PC_Elab - (g, sc1, + (g1, sc1, sc_ty, elab_pats', bnds, (FStar_Reflection_Typing.MC_Tok ((Pulse_Typing.elab_env - g), + g1), (Pulse_Elaborate_Pure.elab_term sc1), (Pulse_Elaborate_Pure.elab_term @@ -1496,18 +1513,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (327)) (Prims.of_int (4)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (327)) (Prims.of_int (4)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -1522,18 +1539,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (325)) + (Prims.of_int (328)) (Prims.of_int (17)) - (Prims.of_int (325)) + (Prims.of_int (328)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (326)) + (Prims.of_int (329)) (Prims.of_int (2)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -1551,18 +1568,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (326)) + (Prims.of_int (329)) (Prims.of_int (2)) - (Prims.of_int (327)) + (Prims.of_int (330)) (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (327)) + (Prims.of_int (330)) (Prims.of_int (61)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (if FStar_Pervasives_Native.uu___is_None new_pats @@ -1570,7 +1587,7 @@ let (check : Obj.magic (Obj.repr (Pulse_Typing_Env.fail - g + g1 (FStar_Pervasives_Native.Some sc_range) "failed to readback new patterns")) @@ -1591,18 +1608,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (328)) + (Prims.of_int (331)) (Prims.of_int (12)) - (Prims.of_int (328)) + (Prims.of_int (331)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (341)) + (Prims.of_int (344)) (Prims.of_int (50)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (Obj.magic (Pulse_Common.zipWith (fun @@ -1637,21 +1654,21 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (343)) + (Prims.of_int (346)) (Prims.of_int (28)) - (Prims.of_int (343)) + (Prims.of_int (346)) (Prims.of_int (116))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (341)) + (Prims.of_int (344)) (Prims.of_int (50)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (Obj.magic (check_branches - g pre () + g1 pre () post_hint check1 sc_u @@ -1676,23 +1693,24 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (348)) + (Prims.of_int (351)) (Prims.of_int (10)) - (Prims.of_int (348)) + (Prims.of_int (351)) (Prims.of_int (83))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Match.fst" - (Prims.of_int (349)) + (Prims.of_int (352)) (Prims.of_int (2)) - (Prims.of_int (349)) - (Prims.of_int (44))))) + (Prims.of_int (352)) + (Prims.of_int (55))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> Pulse_Typing.T_Match - (g, sc_u, + (g1, + sc_u, sc_ty, sc1, (), (), c, @@ -1719,7 +1737,8 @@ let (check : Pulse_Syntax_Base.brs = brs2 })), c, - d)))) + d)) + res_ppname)) uu___5))) uu___4))) uu___4))) @@ -1728,5 +1747,6 @@ let (check : uu___2))) uu___1))) uu___1))) - uu___))) uu___))) - uu___))) uu___) \ No newline at end of file + uu___))) + uu___))) uu___))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Par.ml b/src/ocaml/plugin/generated/Pulse_Checker_Par.ml index 85d374e87..b31265ac4 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Par.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Par.ml @@ -4,136 +4,138 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (23)) (Prims.of_int (10)) - (Prims.of_int (23)) (Prims.of_int (44))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (23)) (Prims.of_int (47)) - (Prims.of_int (54)) (Prims.of_int (50))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "check_par" - t.Pulse_Syntax_Base.range2 g)) - (fun uu___ -> - (fun g1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (25)) (Prims.of_int (50)) - (Prims.of_int (25)) (Prims.of_int (56))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (23)) (Prims.of_int (47)) - (Prims.of_int (54)) (Prims.of_int (50))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_Par - { Pulse_Syntax_Base.pre1 = preL; - Pulse_Syntax_Base.body11 = eL; - Pulse_Syntax_Base.post11 = postL; - Pulse_Syntax_Base.pre2 = preR; - Pulse_Syntax_Base.body21 = eR; - Pulse_Syntax_Base.post2 = postR;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (27)) - (Prims.of_int (4)) - (Prims.of_int (27)) - (Prims.of_int (49))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (25)) - (Prims.of_int (59)) - (Prims.of_int (54)) - (Prims.of_int (50))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_with_expected_type - g1 preL - Pulse_Syntax_Base.tm_vprop)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 - (preL1, preL_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (29)) - (Prims.of_int (4)) - (Prims.of_int (29)) - (Prims.of_int (49))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Par.fst" - (Prims.of_int (27)) - (Prims.of_int (52)) - (Prims.of_int (54)) - (Prims.of_int (50))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_with_expected_type - g1 preR - Pulse_Syntax_Base.tm_vprop)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 - with - | Prims.Mkdtuple2 - (preR1, + fun res_ppname -> + fun t -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Par.fst" + (Prims.of_int (25)) (Prims.of_int (10)) + (Prims.of_int (25)) (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Par.fst" + (Prims.of_int (25)) (Prims.of_int (47)) + (Prims.of_int (60)) (Prims.of_int (95))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "check_par" + t.Pulse_Syntax_Base.range2 g)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (27)) (Prims.of_int (50)) + (Prims.of_int (27)) (Prims.of_int (56))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (25)) (Prims.of_int (47)) + (Prims.of_int (60)) (Prims.of_int (95))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_Par + { Pulse_Syntax_Base.pre1 = preL; + Pulse_Syntax_Base.body11 = eL; + Pulse_Syntax_Base.post11 = postL; + Pulse_Syntax_Base.pre2 = preR; + Pulse_Syntax_Base.body21 = eR; + Pulse_Syntax_Base.post2 = postR;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (29)) + (Prims.of_int (4)) + (Prims.of_int (29)) + (Prims.of_int (49))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (27)) + (Prims.of_int (59)) + (Prims.of_int (60)) + (Prims.of_int (95))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_with_expected_type + g1 preL + Pulse_Syntax_Base.tm_vprop)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 + (preL1, preL_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (31)) + (Prims.of_int (4)) + (Prims.of_int (31)) + (Prims.of_int (49))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (29)) + (Prims.of_int (52)) + (Prims.of_int (60)) + (Prims.of_int (95))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_with_expected_type + g1 preR + Pulse_Syntax_Base.tm_vprop)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 + with + | Prims.Mkdtuple2 + (preR1, preR_typing) - -> - Obj.magic + -> + Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (31)) + (Prims.of_int (33)) (Prims.of_int (19)) - (Prims.of_int (31)) + (Prims.of_int (33)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (31)) + (Prims.of_int (33)) (Prims.of_int (55)) - (Prims.of_int (54)) - (Prims.of_int (50))))) + (Prims.of_int (60)) + (Prims.of_int (95))))) (Obj.magic (Pulse_Checker_Base.intro_post_hint g1 @@ -151,43 +153,70 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (33)) + (Prims.of_int (35)) (Prims.of_int (31)) - (Prims.of_int (36)) - (Prims.of_int (28))))) + (Prims.of_int (39)) + (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (31)) + (Prims.of_int (33)) (Prims.of_int (55)) - (Prims.of_int (54)) - (Prims.of_int (50))))) + (Prims.of_int (60)) + (Prims.of_int (95))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (35)) - (Prims.of_int (6)) - (Prims.of_int (35)) - (Prims.of_int (55))))) + (Prims.of_int (36)) + (Prims.of_int (17)) + (Prims.of_int (36)) + (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" (Prims.of_int (36)) + (Prims.of_int (47)) + (Prims.of_int (39)) + (Prims.of_int (35))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_par_l")) + (fun + uu___3 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (38)) + (Prims.of_int (6)) + (Prims.of_int (38)) + (Prims.of_int (62))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (39)) (Prims.of_int (4)) - (Prims.of_int (36)) - (Prims.of_int (28))))) + (Prims.of_int (39)) + (Prims.of_int (35))))) (Obj.magic (check1 g1 preL1 () (FStar_Pervasives_Native.Some postL_hint) - eL)) + ppname eL)) (fun uu___3 -> (fun r -> @@ -195,7 +224,8 @@ let (check : (Pulse_Checker_Base.apply_checker_result_k g1 preL1 postL_hint - r)) + r ppname)) + uu___3))) uu___3))) (fun uu___3 -> @@ -218,22 +248,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (40)) + (Prims.of_int (43)) (Prims.of_int (20)) - (Prims.of_int (40)) + (Prims.of_int (43)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (40)) + (Prims.of_int (43)) (Prims.of_int (57)) - (Prims.of_int (53)) - (Prims.of_int (52))))) + (Prims.of_int (58)) + (Prims.of_int (96))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> - Pulse_Typing_Metatheory.st_typing_correctness + Pulse_Typing_Metatheory_Base.st_typing_correctness g1 eL1 cL eL_typing)) (fun @@ -247,18 +277,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (41)) + (Prims.of_int (44)) (Prims.of_int (21)) - (Prims.of_int (41)) + (Prims.of_int (44)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (41)) + (Prims.of_int (44)) (Prims.of_int (57)) - (Prims.of_int (53)) - (Prims.of_int (52))))) + (Prims.of_int (58)) + (Prims.of_int (96))))) (Obj.magic (Pulse_Checker_Base.intro_post_hint g1 @@ -276,43 +306,70 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (42)) - (Prims.of_int (33)) (Prims.of_int (45)) - (Prims.of_int (30))))) + (Prims.of_int (33)) + (Prims.of_int (49)) + (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (41)) + (Prims.of_int (44)) (Prims.of_int (57)) - (Prims.of_int (53)) - (Prims.of_int (52))))) + (Prims.of_int (58)) + (Prims.of_int (96))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (44)) + (Prims.of_int (46)) + (Prims.of_int (19)) + (Prims.of_int (46)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (46)) + (Prims.of_int (49)) + (Prims.of_int (49)) + (Prims.of_int (37))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_par_r")) + (fun + uu___4 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (48)) (Prims.of_int (8)) - (Prims.of_int (44)) - (Prims.of_int (57))))) + (Prims.of_int (48)) + (Prims.of_int (64))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (45)) + (Prims.of_int (49)) (Prims.of_int (6)) - (Prims.of_int (45)) - (Prims.of_int (30))))) + (Prims.of_int (49)) + (Prims.of_int (37))))) (Obj.magic (check1 g1 preR1 () (FStar_Pervasives_Native.Some postR_hint) - eR)) + ppname eR)) (fun uu___4 -> (fun r -> @@ -320,7 +377,8 @@ let (check : (Pulse_Checker_Base.apply_checker_result_k g1 preR1 postR_hint - r)) + r ppname)) + uu___4))) uu___4))) (fun uu___4 -> @@ -348,22 +406,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (49)) + (Prims.of_int (53)) (Prims.of_int (22)) - (Prims.of_int (49)) + (Prims.of_int (53)) (Prims.of_int (56))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (49)) + (Prims.of_int (53)) (Prims.of_int (59)) - (Prims.of_int (52)) - (Prims.of_int (59))))) + (Prims.of_int (56)) + (Prims.of_int (79))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> - Pulse_Typing_Metatheory.st_typing_correctness + Pulse_Typing_Metatheory_Base.st_typing_correctness g1 eR1 cR eR_typing)) (fun @@ -377,18 +435,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (50)) + (Prims.of_int (54)) (Prims.of_int (14)) - (Prims.of_int (50)) + (Prims.of_int (54)) (Prims.of_int (21))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (50)) + (Prims.of_int (54)) (Prims.of_int (24)) - (Prims.of_int (52)) - (Prims.of_int (59))))) + (Prims.of_int (56)) + (Prims.of_int (79))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> @@ -403,18 +461,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (51)) + (Prims.of_int (55)) (Prims.of_int (14)) - (Prims.of_int (51)) + (Prims.of_int (55)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (52)) + (Prims.of_int (56)) (Prims.of_int (6)) - (Prims.of_int (52)) - (Prims.of_int (59))))) + (Prims.of_int (56)) + (Prims.of_int (79))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> @@ -435,18 +493,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (52)) - (Prims.of_int (13)) - (Prims.of_int (52)) - (Prims.of_int (41))))) + (Prims.of_int (56)) + (Prims.of_int (22)) + (Prims.of_int (56)) + (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Par.fst" - (Prims.of_int (52)) + (Prims.of_int (56)) (Prims.of_int (6)) - (Prims.of_int (52)) - (Prims.of_int (59))))) + (Prims.of_int (56)) + (Prims.of_int (79))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -472,13 +530,14 @@ let (check : })) (Pulse_Typing.comp_par cL cR x) - d)) + d + res_ppname)) (fun uu___5 -> (fun uu___5 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___5 post_hint @@ -489,22 +548,130 @@ let (check : uu___5)) else Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (58)) + (Prims.of_int (11)) + (Prims.of_int (58)) + (Prims.of_int (96))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (57)) + (Prims.of_int (9)) + (Prims.of_int (58)) + (Prims.of_int (96))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (58)) + (Prims.of_int (74)) + (Prims.of_int (58)) + (Prims.of_int (95))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.comp_to_string + cR)) + (fun + uu___6 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___7 -> + Prims.strcat + "check_par: right computation is not stt (" + (Prims.strcat + uu___6 + ")"))))) + (fun + uu___6 -> + (fun + uu___6 -> + Obj.magic (Pulse_Typing_Env.fail g1 (FStar_Pervasives_Native.Some (eR1.Pulse_Syntax_Base.range2)) - "par: cR is not stt")) + uu___6)) + uu___6))) uu___4))) uu___4))) uu___4)) else Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (60)) + (Prims.of_int (11)) + (Prims.of_int (60)) + (Prims.of_int (95))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (59)) + (Prims.of_int (7)) + (Prims.of_int (60)) + (Prims.of_int (95))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Par.fst" + (Prims.of_int (60)) + (Prims.of_int (73)) + (Prims.of_int (60)) + (Prims.of_int (94))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.comp_to_string + cL)) + (fun + uu___5 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___6 -> + Prims.strcat + "check_par: left computation is not stt (" + (Prims.strcat + uu___5 + ")"))))) + (fun + uu___5 -> + (fun + uu___5 -> + Obj.magic (Pulse_Typing_Env.fail g1 (FStar_Pervasives_Native.Some (eL1.Pulse_Syntax_Base.range2)) - "par: cL is not stt")) + uu___5)) + uu___5))) uu___3))) uu___3))) - uu___2))) - uu___1))) uu___))) uu___) \ No newline at end of file + uu___2))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover.ml index 360b5c6b9..052fc57ba 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover.ml @@ -171,17 +171,17 @@ let rec (match_q : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (75)) + (Prims.of_int (77)) (Prims.of_int (12)) - (Prims.of_int (75)) + (Prims.of_int (77)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (75)) + (Prims.of_int (77)) (Prims.of_int (38)) - (Prims.of_int (84)) + (Prims.of_int (86)) (Prims.of_int (38))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -195,17 +195,17 @@ let rec (match_q : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (77)) + (Prims.of_int (79)) (Prims.of_int (6)) - (Prims.of_int (77)) + (Prims.of_int (79)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (78)) + (Prims.of_int (80)) (Prims.of_int (4)) - (Prims.of_int (84)) + (Prims.of_int (86)) (Prims.of_int (38))))) (Obj.magic (Pulse_Checker_Prover_Match.match_step @@ -236,17 +236,17 @@ let rec (match_q : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (82)) + (Prims.of_int (84)) (Prims.of_int (8)) - (Prims.of_int (83)) + (Prims.of_int (85)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (84)) + (Prims.of_int (86)) (Prims.of_int (6)) - (Prims.of_int (84)) + (Prims.of_int (86)) (Prims.of_int (38))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -299,13 +299,13 @@ let rec (prove_pures : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (93)) (Prims.of_int (18)) - (Prims.of_int (93)) (Prims.of_int (57))))) + (Prims.of_int (95)) (Prims.of_int (18)) + (Prims.of_int (95)) (Prims.of_int (57))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (94)) (Prims.of_int (4)) - (Prims.of_int (101)) (Prims.of_int (12))))) + (Prims.of_int (96)) (Prims.of_int (4)) + (Prims.of_int (104)) (Prims.of_int (12))))) (Obj.magic (Pulse_Checker_Prover_IntroPure.intro_pure preamble pst p unsolved' ())) @@ -319,28 +319,28 @@ let rec (prove_pures : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (95)) - (Prims.of_int (32)) - (Prims.of_int (95)) - (Prims.of_int (94))))) + (Prims.of_int (98)) + (Prims.of_int (24)) + (Prims.of_int (98)) + (Prims.of_int (100))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (95)) - (Prims.of_int (15)) - (Prims.of_int (95)) - (Prims.of_int (94))))) + (Prims.of_int (98)) + (Prims.of_int (7)) + (Prims.of_int (98)) + (Prims.of_int (100))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (95)) - (Prims.of_int (73)) - (Prims.of_int (95)) - (Prims.of_int (93))))) + (Prims.of_int (98)) + (Prims.of_int (79)) + (Prims.of_int (98)) + (Prims.of_int (99))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range @@ -356,7 +356,7 @@ let rec (prove_pures : FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> Prims.strcat - "cannot prove pure " + "prover error: cannot prove pure " (Prims.strcat uu___1 "\n"))))) (fun uu___1 -> @@ -373,17 +373,17 @@ let rec (prove_pures : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (97)) + (Prims.of_int (100)) (Prims.of_int (18)) - (Prims.of_int (97)) + (Prims.of_int (100)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (97)) + (Prims.of_int (100)) (Prims.of_int (11)) - (Prims.of_int (97)) + (Prims.of_int (100)) (Prims.of_int (15))))) (Obj.magic (prove_pures preamble pst1)) (fun pst2 -> @@ -392,9 +392,51 @@ let rec (prove_pures : | uu___ -> Obj.magic (Obj.repr - (Pulse_Typing_Env.fail pst.Pulse_Checker_Prover_Base.pg - FStar_Pervasives_Native.None "prove_pures: not a pure"))) - uu___1 uu___ + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (107)) (Prims.of_int (6)) + (Prims.of_int (108)) (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (106)) (Prims.of_int (4)) + (Prims.of_int (108)) (Prims.of_int (48))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (108)) (Prims.of_int (9)) + (Prims.of_int (108)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + (FStar_List_Tot_Base.hd + pst.Pulse_Checker_Prover_Base.unsolved))) + (fun uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Prims.strcat + "Impossible! prover.prove_pures: " + (Prims.strcat uu___1 + " is not a pure, please file a bug-report"))))) + (fun uu___1 -> + (fun uu___1 -> + Obj.magic + (Pulse_Typing_Env.fail + pst.Pulse_Checker_Prover_Base.pg + FStar_Pervasives_Native.None uu___1)) + uu___1)))) uu___1 uu___ let rec (prover : Pulse_Checker_Prover_Base.preamble -> unit Pulse_Checker_Prover_Base.prover_state -> @@ -407,12 +449,12 @@ let rec (prover : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (111)) (Prims.of_int (2)) (Prims.of_int (114)) + (Prims.of_int (117)) (Prims.of_int (2)) (Prims.of_int (120)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (116)) (Prims.of_int (2)) (Prims.of_int (155)) + (Prims.of_int (122)) (Prims.of_int (2)) (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -422,13 +464,13 @@ let rec (prover : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (114)) (Prims.of_int (6)) - (Prims.of_int (114)) (Prims.of_int (54))))) + (Prims.of_int (120)) (Prims.of_int (6)) + (Prims.of_int (120)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (112)) (Prims.of_int (4)) - (Prims.of_int (114)) (Prims.of_int (54))))) + (Prims.of_int (118)) (Prims.of_int (4)) + (Prims.of_int (120)) (Prims.of_int (54))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string (Pulse_Typing_Combinators.list_as_vprop @@ -441,17 +483,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (4)) - (Prims.of_int (114)) + (Prims.of_int (120)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (112)) + (Prims.of_int (118)) (Prims.of_int (4)) - (Prims.of_int (114)) + (Prims.of_int (120)) (Prims.of_int (54))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -459,9 +501,9 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (113)) + (Prims.of_int (119)) (Prims.of_int (6)) - (Prims.of_int (113)) + (Prims.of_int (119)) (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic @@ -504,14 +546,14 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (119)) (Prims.of_int (14)) - (Prims.of_int (119)) (Prims.of_int (45))))) + (Prims.of_int (125)) (Prims.of_int (14)) + (Prims.of_int (125)) (Prims.of_int (45))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (121)) (Prims.of_int (4)) - (Prims.of_int (155)) (Prims.of_int (32))))) + (Prims.of_int (127)) (Prims.of_int (4)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_ElimExists.elim_exists_pst preamble pst0)) @@ -523,17 +565,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (121)) + (Prims.of_int (127)) (Prims.of_int (4)) - (Prims.of_int (123)) + (Prims.of_int (129)) (Prims.of_int (62))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (123)) + (Prims.of_int (129)) (Prims.of_int (63)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -544,9 +586,9 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (123)) + (Prims.of_int (129)) (Prims.of_int (8)) - (Prims.of_int (123)) + (Prims.of_int (129)) (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic @@ -575,17 +617,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (125)) + (Prims.of_int (131)) (Prims.of_int (14)) - (Prims.of_int (125)) + (Prims.of_int (131)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (127)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_ElimPure.elim_pure_pst @@ -598,17 +640,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (127)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (129)) + (Prims.of_int (135)) (Prims.of_int (62))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (129)) + (Prims.of_int (135)) (Prims.of_int (63)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -620,9 +662,9 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (129)) + (Prims.of_int (135)) (Prims.of_int (8)) - (Prims.of_int (129)) + (Prims.of_int (135)) (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic @@ -654,17 +696,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (131)) + (Prims.of_int (137)) (Prims.of_int (29)) - (Prims.of_int (131)) + (Prims.of_int (137)) (Prims.of_int (82))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (129)) + (Prims.of_int (135)) (Prims.of_int (63)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -691,17 +733,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (133)) + (Prims.of_int (139)) (Prims.of_int (4)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (87))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (88)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -713,17 +755,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (47)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (86))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (134)) + (Prims.of_int (140)) (Prims.of_int (6)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (86))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -739,17 +781,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (134)) + (Prims.of_int (140)) (Prims.of_int (6)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (86))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (134)) + (Prims.of_int (140)) (Prims.of_int (6)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (86))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -757,9 +799,9 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (8)) - (Prims.of_int (135)) + (Prims.of_int (141)) (Prims.of_int (46))))) (FStar_Sealed.seal (Obj.magic @@ -805,17 +847,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (137)) + (Prims.of_int (143)) (Prims.of_int (14)) - (Prims.of_int (137)) + (Prims.of_int (143)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (139)) + (Prims.of_int (145)) (Prims.of_int (4)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -836,17 +878,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (139)) + (Prims.of_int (145)) (Prims.of_int (4)) - (Prims.of_int (141)) + (Prims.of_int (147)) (Prims.of_int (56))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (143)) + (Prims.of_int (149)) (Prims.of_int (4)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -858,9 +900,9 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (141)) + (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (141)) + (Prims.of_int (147)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic @@ -916,17 +958,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (147)) + (Prims.of_int (153)) (Prims.of_int (33)) - (Prims.of_int (147)) + (Prims.of_int (153)) (Prims.of_int (85))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (146)) + (Prims.of_int (152)) (Prims.of_int (10)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -953,17 +995,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (148)) + (Prims.of_int (154)) (Prims.of_int (16)) - (Prims.of_int (148)) + (Prims.of_int (154)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (149)) - (Prims.of_int (6)) (Prims.of_int (155)) + (Prims.of_int (6)) + (Prims.of_int (168)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1002,17 +1044,17 @@ let rec (prover : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (152)) + (Prims.of_int (158)) (Prims.of_int (22)) - (Prims.of_int (152)) + (Prims.of_int (158)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (153)) + (Prims.of_int (159)) (Prims.of_int (8)) - (Prims.of_int (155)) + (Prims.of_int (168)) (Prims.of_int (32))))) (Obj.magic (match_q @@ -1031,10 +1073,244 @@ let rec (prover : FStar_Pervasives_Native.None -> Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (167)) + (Prims.of_int (10)) + (Prims.of_int (167)) + (Prims.of_int (30))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (166)) + (Prims.of_int (12)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + preamble.Pulse_Checker_Prover_Base.ctxt)) + (fun + uu___9 -> + (fun + uu___9 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (165)) + (Prims.of_int (12)) + (Prims.of_int (165)) + (Prims.of_int (45))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + preamble.Pulse_Checker_Prover_Base.goals)) + (fun + uu___10 + -> + (fun + uu___10 + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (164)) + (Prims.of_int (12)) + (Prims.of_int (164)) + (Prims.of_int (65))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + (Pulse_Typing_Combinators.list_as_vprop + pst3.Pulse_Checker_Prover_Base.remaining_ctxt))) + (fun + uu___11 + -> + (fun + uu___11 + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (161)) + (Prims.of_int (20)) + (Prims.of_int (166)) + (Prims.of_int (44))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (163)) + (Prims.of_int (12)) + (Prims.of_int (163)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + q)) + (fun + uu___12 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___13 + -> + fun x -> + fun x1 -> + fun x2 -> + Prims.strcat + (Prims.strcat + (Prims.strcat + (Prims.strcat + "cannot prove vprop " + (Prims.strcat + uu___12 + " in the context: ")) + (Prims.strcat + x + "\n(the prover was started with goal ")) + (Prims.strcat + x1 + " and initial context ")) + (Prims.strcat + x2 ")"))))) + (fun + uu___12 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___13 + -> + uu___12 + uu___11)))) + uu___11))) + (fun + uu___11 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___12 + -> + uu___11 + uu___10)))) + uu___10))) + (fun + uu___10 + -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___11 + -> + uu___10 + uu___9)))) + uu___9))) + (fun + uu___9 -> + (fun msg + -> + Obj.magic (Pulse_Typing_Env.fail pst3.Pulse_Checker_Prover_Base.pg FStar_Pervasives_Native.None - "cannot match a vprop") + msg)) + uu___9)) | FStar_Pervasives_Native.Some pst4 -> @@ -1094,13 +1370,13 @@ let (prove : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (179)) (Prims.of_int (2)) - (Prims.of_int (181)) (Prims.of_int (55))))) + (Prims.of_int (192)) (Prims.of_int (2)) + (Prims.of_int (194)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (181)) (Prims.of_int (56)) - (Prims.of_int (244)) (Prims.of_int (97))))) + (Prims.of_int (194)) (Prims.of_int (56)) + (Prims.of_int (258)) (Prims.of_int (97))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover g (fun uu___ -> @@ -1109,14 +1385,14 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (181)) (Prims.of_int (30)) - (Prims.of_int (181)) (Prims.of_int (54))))) + (Prims.of_int (194)) (Prims.of_int (30)) + (Prims.of_int (194)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (180)) (Prims.of_int (4)) - (Prims.of_int (181)) (Prims.of_int (54))))) + (Prims.of_int (193)) (Prims.of_int (4)) + (Prims.of_int (194)) (Prims.of_int (54))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string goals)) (fun uu___1 -> @@ -1127,17 +1403,17 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (180)) + (Prims.of_int (193)) (Prims.of_int (4)) - (Prims.of_int (181)) + (Prims.of_int (194)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (180)) + (Prims.of_int (193)) (Prims.of_int (4)) - (Prims.of_int (181)) + (Prims.of_int (194)) (Prims.of_int (54))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1145,9 +1421,9 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (181)) + (Prims.of_int (194)) (Prims.of_int (6)) - (Prims.of_int (181)) + (Prims.of_int (194)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic @@ -1183,133 +1459,97 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (183)) (Prims.of_int (15)) - (Prims.of_int (183)) (Prims.of_int (33))))) + (Prims.of_int (196)) (Prims.of_int (15)) + (Prims.of_int (196)) (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (185)) (Prims.of_int (2)) - (Prims.of_int (244)) (Prims.of_int (97))))) + (Prims.of_int (210)) (Prims.of_int (6)) + (Prims.of_int (258)) (Prims.of_int (97))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Typing_Combinators.vprop_as_list ctxt)) (fun uu___1 -> (fun ctxt_l -> - if - (Prims.uu___is_Nil - (Pulse_Typing_Env.bindings uvs)) - && - (FStar_List_Tot_Base.existsb - (fun v -> - Pulse_Syntax_Base.eq_tm v goals) - ctxt_l) - then - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - match get_q_at_hd g ctxt_l - goals - with - | Prims.Mkdtuple2 (l', d_eq) -> - FStar_Pervasives.Mkdtuple4 - (g, [], - (Pulse_Typing_Combinators.list_as_vprop - l'), - (Pulse_Checker_Base.k_elab_equiv - g g ctxt ctxt ctxt - (Pulse_Checker_Prover_Base.op_Star - (Pulse_Checker_Prover_Substs.nt_subst_term - goals []) - (Pulse_Typing_Combinators.list_as_vprop - l')) - (Pulse_Checker_Base.k_elab_unit - g ctxt) () ()))))) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (198)) - (Prims.of_int (61)) - (Prims.of_int (198)) - (Prims.of_int (69))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (198)) - (Prims.of_int (72)) - (Prims.of_int (244)) - (Prims.of_int (97))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> ())) - (fun uu___2 -> - (fun ctxt_frame_typing -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (200)) - (Prims.of_int (6)) - (Prims.of_int (204)) - (Prims.of_int (12))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (207)) - (Prims.of_int (43)) - (Prims.of_int (244)) - (Prims.of_int (97))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - { - Pulse_Checker_Prover_Base.g0 - = g; - Pulse_Checker_Prover_Base.ctxt - = ctxt; - Pulse_Checker_Prover_Base.frame - = - Pulse_Syntax_Base.tm_emp; - Pulse_Checker_Prover_Base.ctxt_frame_typing - = (); - Pulse_Checker_Prover_Base.goals - = goals - })) - (fun uu___2 -> - (fun preamble -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - ( - Obj.magic - (FStar_Range.mk_range + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (211)) + (Prims.of_int (61)) + (Prims.of_int (211)) + (Prims.of_int (69))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (211)) + (Prims.of_int (72)) + (Prims.of_int (258)) + (Prims.of_int (97))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> ())) + (fun uu___1 -> + (fun ctxt_frame_typing -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (213)) + (Prims.of_int (6)) + (Prims.of_int (217)) + (Prims.of_int (12))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (220)) + (Prims.of_int (43)) + (Prims.of_int (258)) + (Prims.of_int (97))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + { + Pulse_Checker_Prover_Base.g0 + = g; + Pulse_Checker_Prover_Base.ctxt + = ctxt; + Pulse_Checker_Prover_Base.frame + = + Pulse_Syntax_Base.tm_emp; + Pulse_Checker_Prover_Base.ctxt_frame_typing + = (); + Pulse_Checker_Prover_Base.goals + = goals + })) + (fun uu___1 -> + (fun preamble -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (209)) + (Prims.of_int (222)) (Prims.of_int (6)) - (Prims.of_int (218)) + (Prims.of_int (231)) (Prims.of_int (21))))) - (FStar_Sealed.seal - ( - Obj.magic - (FStar_Range.mk_range + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (219)) + (Prims.of_int (232)) (Prims.of_int (8)) - (Prims.of_int (244)) + (Prims.of_int (258)) (Prims.of_int (97))))) - (FStar_Tactics_Effect.lift_div_tac - ( - fun - uu___2 -> - { + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + { Pulse_Checker_Prover_Base.pg = g; Pulse_Checker_Prover_Base.remaining_ctxt @@ -1354,35 +1594,34 @@ let (prove : = (); Pulse_Checker_Prover_Base.solved_inv = () - })) - (fun uu___2 - -> - (fun pst0 - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind + })) + (fun uu___1 -> + (fun pst0 -> + Obj.magic + ( + FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (221)) + (Prims.of_int (234)) (Prims.of_int (14)) - (Prims.of_int (221)) + (Prims.of_int (234)) (Prims.of_int (25))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (221)) + (Prims.of_int (234)) (Prims.of_int (28)) - (Prims.of_int (244)) + (Prims.of_int (258)) (Prims.of_int (97))))) (Obj.magic (prover preamble pst0)) (fun - uu___2 -> + uu___1 -> (fun pst -> Obj.magic @@ -1391,17 +1630,17 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (223)) + (Prims.of_int (236)) (Prims.of_int (15)) - (Prims.of_int (223)) + (Prims.of_int (236)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (225)) + (Prims.of_int (238)) (Prims.of_int (4)) - (Prims.of_int (244)) + (Prims.of_int (258)) (Prims.of_int (97))))) (Obj.magic (Pulse_Checker_Prover_Substs.ss_to_nt_substs @@ -1409,7 +1648,7 @@ let (prove : pst.Pulse_Checker_Prover_Base.uvs pst.Pulse_Checker_Prover_Base.ss)) (fun - uu___2 -> + uu___1 -> (fun ropt -> Obj.magic @@ -1418,17 +1657,17 @@ let (prove : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (225)) + (Prims.of_int (238)) (Prims.of_int (4)) - (Prims.of_int (225)) - (Prims.of_int (66))))) + (Prims.of_int (239)) + (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (225)) - (Prims.of_int (67)) - (Prims.of_int (244)) + (Prims.of_int (239)) + (Prims.of_int (66)) + (Prims.of_int (258)) (Prims.of_int (97))))) (if FStar_Pervasives_Native.uu___is_None @@ -1439,19 +1678,19 @@ let (prove : (Pulse_Typing_Env.fail pst.Pulse_Checker_Prover_Base.pg FStar_Pervasives_Native.None - "prove: ss not well-typed")) + "prover error: ill-typed substitutions")) else Obj.magic (Obj.repr (FStar_Tactics_Effect.lift_div_tac (fun - uu___3 -> + uu___2 -> ())))) (fun - uu___2 -> + uu___1 -> FStar_Tactics_Effect.lift_div_tac (fun - uu___3 -> + uu___2 -> match ropt with | @@ -1491,10 +1730,10 @@ let (prove : pst.Pulse_Checker_Prover_Base.remaining_ctxt)) pst.Pulse_Checker_Prover_Base.k () ())))))) - uu___2))) - uu___2))) - uu___2))) - uu___2))) uu___2)))) + uu___1))) + uu___1))) + uu___1))) + uu___1))) uu___1))) uu___1))) uu___) let (try_frame_pre_uvs : Pulse_Typing_Env.env -> @@ -1504,8 +1743,9 @@ let (try_frame_pre_uvs : Pulse_Syntax_Base.st_term -> Pulse_Syntax_Base.comp_st -> (unit, unit, unit) Pulse_Typing.st_typing -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> @@ -1514,122 +1754,156 @@ let (try_frame_pre_uvs : fun t -> fun c -> fun d -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (255)) (Prims.of_int (4)) - (Prims.of_int (255)) (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (252)) (Prims.of_int (42)) - (Prims.of_int (290)) (Prims.of_int (27))))) - (Obj.magic - (prove g ctxt () uvs (Pulse_Syntax_Base.comp_pre c) ())) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple4 - (g1, nts, remaining_ctxt, k_frame) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (259)) - (Prims.of_int (4)) - (Prims.of_int (259)) - (Prims.of_int (64))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (261)) - (Prims.of_int (82)) - (Prims.of_int (290)) - (Prims.of_int (27))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Checker_Prover_Util.st_typing_weakening - g uvs t c d g1)) - (fun uu___1 -> - (fun d1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (262)) - (Prims.of_int (10)) - (Prims.of_int (262)) - (Prims.of_int (35))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (262)) - (Prims.of_int (38)) - (Prims.of_int (290)) - (Prims.of_int (27))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Checker_Prover_Substs.nt_subst_st_term - t nts)) - (fun uu___1 -> - (fun t1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (263)) - (Prims.of_int (10)) - (Prims.of_int (263)) - (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (263)) - (Prims.of_int (35)) - (Prims.of_int (290)) - (Prims.of_int (27))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Checker_Prover_Substs.nt_subst_comp - c nts)) - (fun uu___1 -> - (fun c1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + fun res_ppname -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (269)) (Prims.of_int (10)) + (Prims.of_int (269)) (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (269)) (Prims.of_int (51)) + (Prims.of_int (325)) (Prims.of_int (65))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "try_frame_pre" + t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (272)) + (Prims.of_int (4)) + (Prims.of_int (272)) + (Prims.of_int (56))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (269)) + (Prims.of_int (51)) + (Prims.of_int (325)) + (Prims.of_int (65))))) + (Obj.magic + (prove g1 ctxt () uvs + (Pulse_Syntax_Base.comp_pre c) ())) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | FStar_Pervasives.Mkdtuple4 + (g11, nts, remaining_ctxt, k_frame) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (276)) + (Prims.of_int (4)) + (Prims.of_int (276)) + (Prims.of_int (49))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (278)) + (Prims.of_int (82)) + (Prims.of_int (325)) + (Prims.of_int (65))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Typing_Metatheory.st_typing_weakening + g1 uvs t c d g11)) + (fun uu___1 -> + (fun d1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (279)) + (Prims.of_int (10)) + (Prims.of_int (279)) + (Prims.of_int (35))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (279)) + (Prims.of_int (38)) + (Prims.of_int (325)) + (Prims.of_int (65))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Checker_Prover_Substs.nt_subst_st_term + t nts)) + (fun uu___1 -> + (fun t1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (280)) + (Prims.of_int (10)) + (Prims.of_int (280)) + (Prims.of_int (32))))) + ( + FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (280)) + (Prims.of_int (35)) + (Prims.of_int (325)) + (Prims.of_int (65))))) + ( + FStar_Tactics_Effect.lift_div_tac + (fun + uu___1 -> + Pulse_Checker_Prover_Substs.nt_subst_comp + c nts)) + ( + fun + uu___1 -> + (fun c1 + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (266)) + (Prims.of_int (283)) (Prims.of_int (4)) - (Prims.of_int (266)) + (Prims.of_int (283)) (Prims.of_int (47))))) - (FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (266)) + (Prims.of_int (283)) (Prims.of_int (50)) - (Prims.of_int (290)) - (Prims.of_int (27))))) - (FStar_Tactics_Effect.lift_div_tac + (Prims.of_int (325)) + (Prims.of_int (65))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Checker_Prover_Substs.st_typing_nt_substs_derived - g1 uvs t + g11 uvs t c d1 nts)) - (fun uu___1 - -> + (fun + uu___1 -> (fun d2 -> Obj.magic @@ -1638,18 +1912,18 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (268)) + (Prims.of_int (285)) (Prims.of_int (82)) - (Prims.of_int (268)) + (Prims.of_int (285)) (Prims.of_int (102))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (268)) + (Prims.of_int (285)) (Prims.of_int (105)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -1667,23 +1941,23 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (270)) + (Prims.of_int (287)) (Prims.of_int (10)) - (Prims.of_int (270)) + (Prims.of_int (287)) (Prims.of_int (18))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (270)) + (Prims.of_int (287)) (Prims.of_int (21)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Typing_Env.fresh - g1)) + g11)) (fun uu___1 -> (fun x -> @@ -1693,18 +1967,18 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (271)) + (Prims.of_int (288)) (Prims.of_int (11)) - (Prims.of_int (271)) + (Prims.of_int (288)) (Prims.of_int (21))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (271)) + (Prims.of_int (288)) (Prims.of_int (24)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -1720,24 +1994,24 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (272)) + (Prims.of_int (289)) (Prims.of_int (11)) - (Prims.of_int (272)) - (Prims.of_int (46))))) + (Prims.of_int (289)) + (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (273)) - (Prims.of_int (31)) (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (31)) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Typing_Env.push_binding - g1 x - Pulse_Syntax_Base.ppname_default + g11 x + res_ppname ty)) (fun uu___1 -> @@ -1749,18 +2023,18 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (274)) + (Prims.of_int (291)) (Prims.of_int (14)) - (Prims.of_int (274)) - (Prims.of_int (79))))) + (Prims.of_int (291)) + (Prims.of_int (75))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (274)) - (Prims.of_int (82)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (291)) + (Prims.of_int (78)) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -1768,7 +2042,7 @@ let (try_frame_pre_uvs : (Pulse_Syntax_Naming.open_term_nv (Pulse_Syntax_Base.comp_post c1) - (Pulse_Syntax_Base.ppname_default, + (res_ppname, x)) remaining_ctxt)) (fun @@ -1781,24 +2055,24 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (276)) + (Prims.of_int (293)) (Prims.of_int (29)) - (Prims.of_int (276)) - (Prims.of_int (62))))) + (Prims.of_int (293)) + (Prims.of_int (73))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (276)) - (Prims.of_int (65)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (293)) + (Prims.of_int (76)) + (Prims.of_int (325)) + (Prims.of_int (65))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> - Pulse_Checker_Prover_Util.st_typing_weakening_standard - g1 t1 c1 - d2 g1)) + Pulse_Typing_Metatheory.st_typing_weakening_standard + g11 t1 c1 + d2 g11)) (fun uu___1 -> (fun d3 @@ -1809,34 +2083,56 @@ let (try_frame_pre_uvs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (281)) + (Prims.of_int (298)) (Prims.of_int (4)) - (Prims.of_int (281)) - (Prims.of_int (67))))) + (Prims.of_int (298)) + (Prims.of_int (81))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (290)) - (Prims.of_int (2)) - (Prims.of_int (290)) - (Prims.of_int (27))))) + (Prims.of_int (305)) + (Prims.of_int (35)) + (Prims.of_int (325)) + (Prims.of_int (65))))) (Obj.magic (Pulse_Checker_Base.continuation_elaborator_with_bind - g1 + g11 remaining_ctxt c1 t1 d3 - () x)) + () + (res_ppname, + x))) (fun k -> FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> + match + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion_cofinite + g11 + (Pulse_Syntax_Base.st_comp_of_comp + c1) + (Pulse_Typing_Metatheory_Base.comp_typing_inversion + g11 c1 + (Pulse_Typing_Metatheory_Base.st_typing_correctness + g11 t1 c1 + d3)) + with + | + (comp_res_typing_in_g1, + uu___2, + f) -> FStar_Pervasives.Mkdtuple5 - (x, ty, - ctxt', - g2, + (x, g2, + (FStar_Pervasives.Mkdtuple3 + ((Pulse_Syntax_Base.comp_u + c1), ty, + ())), + (Prims.Mkdtuple2 + (ctxt', + ())), (Pulse_Checker_Base.k_elab_trans - g g1 g2 + g1 g11 g2 ctxt (Pulse_Checker_Prover_Base.op_Star (Pulse_Syntax_Base.comp_pre @@ -1845,7 +2141,7 @@ let (try_frame_pre_uvs : ctxt' k_frame1 (Pulse_Checker_Base.k_elab_equiv - g1 g2 + g11 g2 (Pulse_Checker_Prover_Base.op_Star remaining_ctxt (Pulse_Syntax_Base.comp_pre @@ -1864,8 +2160,9 @@ let (try_frame_pre_uvs : uu___1))) uu___1))) uu___1))) - uu___1))) uu___1))) - uu___1))) uu___) + uu___1))) + uu___1))) + uu___1))) uu___))) uu___) let (try_frame_pre : Pulse_Typing_Env.env -> Pulse_Syntax_Base.vprop -> @@ -1873,8 +2170,9 @@ let (try_frame_pre : Pulse_Syntax_Base.st_term -> Pulse_Syntax_Base.comp_st -> (unit, unit, unit) Pulse_Typing.st_typing -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> @@ -1882,25 +2180,28 @@ let (try_frame_pre : fun t -> fun c -> fun d -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (298)) (Prims.of_int (12)) - (Prims.of_int (298)) (Prims.of_int (32))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (300)) (Prims.of_int (2)) - (Prims.of_int (300)) (Prims.of_int (37))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Typing_Env.mk_env (Pulse_Typing_Env.fstar_env g))) - (fun uu___ -> - (fun uvs -> - Obj.magic (try_frame_pre_uvs g ctxt () uvs t c d)) - uu___) -let (repack : + fun res_ppname -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (333)) (Prims.of_int (12)) + (Prims.of_int (333)) (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (335)) (Prims.of_int (2)) + (Prims.of_int (335)) (Prims.of_int (48))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.mk_env + (Pulse_Typing_Env.fstar_env g))) + (fun uu___ -> + (fun uvs -> + Obj.magic + (try_frame_pre_uvs g ctxt () uvs t c d res_ppname)) + uu___) +let (prove_post_hint : Pulse_Typing_Env.env -> Pulse_Syntax_Base.vprop -> (unit, unit, unit) Pulse_Checker_Base.checker_result_t -> @@ -1909,125 +2210,279 @@ let (repack : ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, unit) FStar_Tactics_Effect.tac_repr) = - fun uu___4 -> - fun uu___3 -> - fun uu___2 -> - fun uu___1 -> - fun uu___ -> - (fun g -> - fun ctxt -> - fun r -> - fun post_hint -> - fun rng -> - match post_hint with - | FStar_Pervasives_Native.None -> - Obj.magic - (Obj.repr + fun g -> + fun ctxt -> + fun r -> + fun post_hint -> + fun rng -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (344)) (Prims.of_int (10)) + (Prims.of_int (344)) (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.fst" + (Prims.of_int (346)) (Prims.of_int (2)) + (Prims.of_int (390)) (Prims.of_int (102))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Typing_Env.push_context g "prove_post_hint" rng)) + (fun uu___ -> + (fun g1 -> + match post_hint with + | FStar_Pervasives_Native.None -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> r))) + | FStar_Pervasives_Native.Some post_hint1 -> + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (349)) + (Prims.of_int (79)) + (Prims.of_int (349)) + (Prims.of_int (80))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (348)) + (Prims.of_int (21)) + (Prims.of_int (390)) + (Prims.of_int (102))))) (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> r))) - | FStar_Pervasives_Native.Some post_hint1 -> - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (312)) - (Prims.of_int (36)) - (Prims.of_int (312)) - (Prims.of_int (37))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (311)) - (Prims.of_int (21)) - (Prims.of_int (336)) - (Prims.of_int (64))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> r)) + (fun uu___ -> r)) + (fun uu___ -> (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple5 - (x, ty, ctxt', g2, k) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (314)) - (Prims.of_int (27)) - (Prims.of_int (314)) - (Prims.of_int (74))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Prover.fst" - (Prims.of_int (317)) - (Prims.of_int (4)) - (Prims.of_int (336)) - (Prims.of_int (64))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - Pulse_Syntax_Naming.open_term_nv - post_hint1.Pulse_Typing.post - (Pulse_Syntax_Base.ppname_default, - x))) + match uu___ with + | FStar_Pervasives.Mkdtuple5 + (x, g2, FStar_Pervasives.Mkdtuple3 + (u_ty, ty, ty_typing), + Prims.Mkdtuple2 + (ctxt', ctxt'_typing), k) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (351)) + (Prims.of_int (17)) + (Prims.of_int (351)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (351)) + (Prims.of_int (47)) + (Prims.of_int (390)) + (Prims.of_int (102))))) + (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> - (fun post_hint_opened -> - if - Prims.op_Negation - (Pulse_Syntax_Base.eq_tm - ty - post_hint1.Pulse_Typing.ret_ty) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail - g - (FStar_Pervasives_Native.Some - rng) - "result type is not the same in stapp")) - else - Obj.magic - (Obj.repr - (if - Pulse_Syntax_Base.eq_tm - post_hint_opened - ctxt' + Pulse_Syntax_Base.mk_ppname_no_range + "_posth")) + (fun uu___1 -> + (fun ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (352)) + (Prims.of_int (27)) + (Prims.of_int (352)) + (Prims.of_int (66))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (355)) + (Prims.of_int (4)) + (Prims.of_int (390)) + (Prims.of_int (102))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + Pulse_Syntax_Naming.open_term_nv + post_hint1.Pulse_Typing.post + (ppname, x))) + (fun uu___1 -> + (fun + post_hint_opened + -> + if + Prims.op_Negation + ( + Pulse_Syntax_Base.eq_tm + ty + post_hint1.Pulse_Typing.ret_ty) then - Obj.repr + Obj.magic ( + Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (357)) + (Prims.of_int (11)) + (Prims.of_int (360)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (356)) + (Prims.of_int (9)) + (Prims.of_int (360)) + (Prims.of_int (50))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (360)) + (Prims.of_int (14)) + (Prims.of_int (360)) + (Prims.of_int (49))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (357)) + (Prims.of_int (11)) + (Prims.of_int (360)) + (Prims.of_int (50))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + post_hint1.Pulse_Typing.ret_ty)) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (357)) + (Prims.of_int (11)) + (Prims.of_int (360)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (357)) + (Prims.of_int (11)) + (Prims.of_int (360)) + (Prims.of_int (50))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (359)) + (Prims.of_int (14)) + (Prims.of_int (359)) + (Prims.of_int (35))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + ty)) + (fun + uu___2 -> FStar_Tactics_Effect.lift_div_tac (fun + uu___3 -> + fun x1 -> + Prims.strcat + (Prims.strcat + "error in proving post hint:comp return type " + (Prims.strcat + uu___2 + " does not match the post hint ")) + (Prims.strcat + x1 ""))))) + (fun uu___2 -> - FStar_Pervasives.Mkdtuple5 - (x, ty, - post_hint_opened, - g2, k))) + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + uu___2 + uu___1)))) + uu___1))) + (fun + uu___1 -> + (fun + uu___1 -> + Obj.magic + (Pulse_Typing_Env.fail + g1 + (FStar_Pervasives_Native.Some + rng) + uu___1)) + uu___1))) else - Obj.repr + Obj.magic ( - FStar_Tactics_Effect.tac_bind + Obj.repr + (if + Pulse_Syntax_Base.eq_tm + post_hint_opened + ctxt' + then + Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___2 -> + FStar_Pervasives.Mkdtuple5 + (x, g2, + (FStar_Pervasives.Mkdtuple3 + (u_ty, + ty, ())), + (Prims.Mkdtuple2 + (ctxt', + ())), k))) + else + Obj.repr + (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (323)) + (Prims.of_int (365)) (Prims.of_int (8)) - (Prims.of_int (323)) - (Prims.of_int (88))))) + (Prims.of_int (365)) + (Prims.of_int (90))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (321)) + (Prims.of_int (363)) (Prims.of_int (8)) - (Prims.of_int (336)) - (Prims.of_int (64))))) + (Prims.of_int (390)) + (Prims.of_int (102))))) (Obj.magic (prove g2 ctxt' () @@ -2054,18 +2509,18 @@ let (repack : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (328)) + (Prims.of_int (370)) (Prims.of_int (8)) - (Prims.of_int (328)) + (Prims.of_int (370)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.fst" - (Prims.of_int (330)) + (Prims.of_int (372)) (Prims.of_int (6)) - (Prims.of_int (336)) - (Prims.of_int (64))))) + (Prims.of_int (390)) + (Prims.of_int (102))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -2086,11 +2541,65 @@ let (repack : -> Obj.magic (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (375)) + (Prims.of_int (10)) + (Prims.of_int (377)) + (Prims.of_int (47))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (374)) + (Prims.of_int (8)) + (Prims.of_int (377)) + (Prims.of_int (47))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.fst" + (Prims.of_int (377)) + (Prims.of_int (13)) + (Prims.of_int (377)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + remaining_ctxt)) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + Prims.strcat + "error in proving post hint:comp post contains extra vprops not matched in the post hint: " + (Prims.strcat + uu___4 + "\n"))))) + (fun + uu___4 -> + (fun + uu___4 -> + Obj.magic (Pulse_Typing_Env.fail - g + g1 (FStar_Pervasives_Native.Some rng) - "cannot match post hint in st app")) + uu___4)) + uu___4))) | FStar_Pervasives_Native.Some d -> @@ -2100,13 +2609,20 @@ let (repack : (fun uu___4 -> FStar_Pervasives.Mkdtuple5 - (x, ty, - post_hint_opened, - g3, + (x, g3, + (FStar_Pervasives.Mkdtuple3 + (u_ty, + ty, ())), + (Prims.Mkdtuple2 + (post_hint_opened, + ())), (Pulse_Checker_Base.k_elab_trans g g2 g3 ctxt - ctxt' + (FStar_Pervasives.dfst + (Prims.Mkdtuple2 + (ctxt', + ()))) post_hint_opened k (Pulse_Checker_Base.k_elab_equiv @@ -2121,5 +2637,5 @@ let (repack : () ()))))))) uu___4))) uu___3))))) - uu___1))) uu___)))) - uu___4 uu___3 uu___2 uu___1 uu___ \ No newline at end of file + uu___1))) + uu___1))) uu___)))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Base.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Base.ml index 922c3277d..a9776ab3c 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Base.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Base.ml @@ -212,7 +212,7 @@ let (elim_one : (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" (Prims.of_int (78)) (Prims.of_int (72)) - (Prims.of_int (101)) (Prims.of_int (40))))) + (Prims.of_int (102)) (Prims.of_int (40))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> ())) (fun uu___ -> (fun ctxt_frame_typing -> @@ -232,7 +232,7 @@ let (elim_one : "Pulse.Checker.Prover.Base.fst" (Prims.of_int (79)) (Prims.of_int (35)) - (Prims.of_int (101)) + (Prims.of_int (102)) (Prims.of_int (40))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -246,71 +246,98 @@ let (elim_one : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (81)) - (Prims.of_int (4)) - (Prims.of_int (81)) - (Prims.of_int (90))))) + (Prims.of_int (80)) + (Prims.of_int (15)) + (Prims.of_int (80)) + (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (101)) - (Prims.of_int (2)) - (Prims.of_int (101)) + (Prims.of_int (80)) + (Prims.of_int (45)) + (Prims.of_int (102)) (Prims.of_int (40))))) - (Obj.magic - (Pulse_Checker_Base.continuation_elaborator_with_bind - g - (Pulse_Syntax_Base.tm_star - ctxt frame) c1 e1 - e1_typing () x)) - (fun k -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - FStar_Pervasives.Mkdtuple4 - ((Pulse_Typing_Env.push_binding - g x nx - (Pulse_Syntax_Base.comp_res - c1)), - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Naming.open_term_nv - (Pulse_Syntax_Base.comp_post - c1) - (Pulse_Syntax_Base.v_as_nv - x)) ctxt), - (), - (Pulse_Checker_Base.k_elab_equiv - g - (Pulse_Typing_Env.push_binding - g x nx - (Pulse_Syntax_Base.comp_res - c1)) - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Base.tm_star - ctxt frame) - p) - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Base.tm_star - ctxt frame) - p) - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Naming.open_term_nv - (Pulse_Syntax_Base.comp_post + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Syntax_Base.mk_ppname_no_range + "_pelim")) + (fun uu___ -> + (fun ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.Base.fst" + (Prims.of_int (82)) + (Prims.of_int (4)) + (Prims.of_int (82)) + (Prims.of_int (100))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.Base.fst" + (Prims.of_int (102)) + (Prims.of_int (2)) + (Prims.of_int (102)) + (Prims.of_int (40))))) + (Obj.magic + (Pulse_Checker_Base.continuation_elaborator_with_bind + g + (Pulse_Syntax_Base.tm_star + ctxt frame) + c1 e1 + e1_typing () + (ppname, x))) + (fun k -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + FStar_Pervasives.Mkdtuple4 + ((Pulse_Typing_Env.push_binding + g x nx + (Pulse_Syntax_Base.comp_res + c1)), + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Naming.open_term_nv + (Pulse_Syntax_Base.comp_post c1) - (Pulse_Syntax_Base.v_as_nv + (Pulse_Syntax_Base.v_as_nv + x)) ctxt), + (), + (Pulse_Checker_Base.k_elab_equiv + g + (Pulse_Typing_Env.push_binding + g x nx + (Pulse_Syntax_Base.comp_res + c1)) + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Base.tm_star + ctxt + frame) p) + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Base.tm_star + ctxt + frame) p) + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Naming.open_term_nv + (Pulse_Syntax_Base.comp_post + c1) + (Pulse_Syntax_Base.v_as_nv x)) - (Pulse_Syntax_Base.tm_star - ctxt frame)) - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Base.tm_star - (Pulse_Syntax_Naming.open_term_nv + (Pulse_Syntax_Base.tm_star + ctxt + frame)) + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Base.tm_star + (Pulse_Syntax_Naming.open_term_nv (Pulse_Syntax_Base.comp_post c1) (Pulse_Syntax_Base.v_as_nv x)) ctxt) - frame) k () - ())))))) uu___))) - uu___) + frame) k + () ())))))) + uu___))) uu___))) uu___) let rec (elim_all : Pulse_Typing_Env.env -> (Pulse_Syntax_Base.vprop -> @@ -351,17 +378,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (116)) + (Prims.of_int (117)) (Prims.of_int (9)) - (Prims.of_int (116)) + (Prims.of_int (117)) (Prims.of_int (89))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (7)) - (Prims.of_int (137)) + (Prims.of_int (138)) (Prims.of_int (10))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> ())) @@ -373,17 +400,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (10)) - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (7)) - (Prims.of_int (137)) + (Prims.of_int (138)) (Prims.of_int (10))))) (Obj.magic (f p)) (fun uu___ -> @@ -397,17 +424,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (118)) + (Prims.of_int (119)) (Prims.of_int (18)) - (Prims.of_int (118)) + (Prims.of_int (119)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (118)) + (Prims.of_int (119)) (Prims.of_int (12)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (70))))) (Obj.magic (mk g p @@ -432,17 +459,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (121)) + (Prims.of_int (122)) (Prims.of_int (16)) - (Prims.of_int (121)) + (Prims.of_int (122)) (Prims.of_int (72))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (119)) + (Prims.of_int (120)) (Prims.of_int (49)) - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (71))))) (Obj.magic (elim_one @@ -470,17 +497,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (124)) + (Prims.of_int (125)) (Prims.of_int (65)) - (Prims.of_int (124)) + (Prims.of_int (125)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (124)) + (Prims.of_int (125)) (Prims.of_int (69)) - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (71))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -496,17 +523,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (128)) - (Prims.of_int (16)) (Prims.of_int (129)) + (Prims.of_int (16)) + (Prims.of_int (130)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (129)) + (Prims.of_int (130)) (Prims.of_int (45)) - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (71))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -538,17 +565,17 @@ let rec (elim_all : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (131)) + (Prims.of_int (132)) (Prims.of_int (16)) - (Prims.of_int (131)) + (Prims.of_int (132)) (Prims.of_int (50))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (129)) + (Prims.of_int (130)) (Prims.of_int (45)) - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (71))))) (Obj.magic (elim_all @@ -666,13 +693,13 @@ let (add_elims_aux : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (151)) (Prims.of_int (40)) - (Prims.of_int (151)) (Prims.of_int (71))))) + (Prims.of_int (152)) (Prims.of_int (40)) + (Prims.of_int (152)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (151)) (Prims.of_int (4)) - (Prims.of_int (154)) (Prims.of_int (66))))) + (Prims.of_int (152)) (Prims.of_int (4)) + (Prims.of_int (155)) (Prims.of_int (66))))) (Obj.magic (canon_right g ctxt frame () f)) (fun uu___ -> (fun uu___ -> @@ -685,17 +712,17 @@ let (add_elims_aux : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (153)) + (Prims.of_int (154)) (Prims.of_int (9)) - (Prims.of_int (153)) + (Prims.of_int (154)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (151)) + (Prims.of_int (152)) (Prims.of_int (74)) - (Prims.of_int (154)) + (Prims.of_int (155)) (Prims.of_int (66))))) (Obj.magic (elim_all g f mk ctxt' frame () uvs)) @@ -746,13 +773,13 @@ let rec (add_elims : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (165)) (Prims.of_int (25)) - (Prims.of_int (165)) (Prims.of_int (59))))) + (Prims.of_int (166)) (Prims.of_int (25)) + (Prims.of_int (166)) (Prims.of_int (59))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (165)) (Prims.of_int (4)) - (Prims.of_int (172)) (Prims.of_int (6))))) + (Prims.of_int (166)) (Prims.of_int (4)) + (Prims.of_int (173)) (Prims.of_int (6))))) (Obj.magic (add_elims_aux g ctxt frame f mk () uvs)) (fun uu___ -> (fun uu___ -> @@ -772,17 +799,17 @@ let rec (add_elims : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (169)) + (Prims.of_int (170)) (Prims.of_int (45)) - (Prims.of_int (169)) + (Prims.of_int (170)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (168)) + (Prims.of_int (169)) (Prims.of_int (10)) - (Prims.of_int (172)) + (Prims.of_int (173)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> res)) @@ -798,17 +825,17 @@ let rec (add_elims : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (170)) + (Prims.of_int (171)) (Prims.of_int (49)) - (Prims.of_int (170)) + (Prims.of_int (171)) (Prims.of_int (80))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Base.fst" - (Prims.of_int (169)) + (Prims.of_int (170)) (Prims.of_int (51)) - (Prims.of_int (171)) + (Prims.of_int (172)) (Prims.of_int (57))))) (Obj.magic (add_elims g' ctxt' diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroExists.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroExists.ml index af5ec2b88..7c8967e13 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroExists.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroExists.ml @@ -36,7 +36,7 @@ let (k_intro_exists : (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" (Prims.of_int (28)) (Prims.of_int (52)) - (Prims.of_int (66)) (Prims.of_int (30))))) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_Typing.wr @@ -65,7 +65,7 @@ let (k_intro_exists : "Pulse.Checker.Prover.IntroExists.fst" (Prims.of_int (30)) (Prims.of_int (38)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -88,7 +88,7 @@ let (k_intro_exists : "Pulse.Checker.Prover.IntroExists.fst" (Prims.of_int (35)) (Prims.of_int (45)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -113,7 +113,7 @@ let (k_intro_exists : "Pulse.Checker.Prover.IntroExists.fst" (Prims.of_int (38)) (Prims.of_int (52)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -127,19 +127,46 @@ let (k_intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (44)) - (Prims.of_int (4)) - (Prims.of_int (44)) - (Prims.of_int (65))))) + (Prims.of_int (40)) + (Prims.of_int (15)) + (Prims.of_int (40)) + (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (52)) + (Prims.of_int (40)) + (Prims.of_int (47)) + (Prims.of_int (67)) + (Prims.of_int (30))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___ -> + Pulse_Syntax_Base.mk_ppname_no_range + "_pintroe")) + (fun uu___ + -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.IntroExists.fst" + (Prims.of_int (45)) + (Prims.of_int (4)) + (Prims.of_int (45)) + (Prims.of_int (75))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.IntroExists.fst" + (Prims.of_int (53)) (Prims.of_int (20)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) - (Obj.magic + (Obj.magic (Pulse_Checker_Base.continuation_elaborator_with_bind g frame (Pulse_Typing.comp_intro_exists @@ -157,8 +184,10 @@ let (k_intro_exists : = [e] })) t_typing - () x)) - (fun k -> + () + (ppname, + x))) + (fun k -> FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -171,17 +200,17 @@ let (k_intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (53)) + (Prims.of_int (54)) (Prims.of_int (25)) - (Prims.of_int (53)) + (Prims.of_int (54)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (52)) + (Prims.of_int (53)) (Prims.of_int (20)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -203,17 +232,17 @@ let (k_intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (54)) + (Prims.of_int (55)) (Prims.of_int (31)) - (Prims.of_int (54)) + (Prims.of_int (55)) (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (54)) + (Prims.of_int (55)) (Prims.of_int (36)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -229,17 +258,17 @@ let (k_intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (55)) + (Prims.of_int (56)) (Prims.of_int (18)) - (Prims.of_int (55)) + (Prims.of_int (56)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (64)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -258,22 +287,22 @@ let (k_intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (60)) + (Prims.of_int (61)) (Prims.of_int (4)) - (Prims.of_int (64)) + (Prims.of_int (65)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (2)) - (Prims.of_int (66)) + (Prims.of_int (67)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> - Pulse_Checker_Prover_Util.st_typing_weakening + Pulse_Typing_Metatheory.st_typing_weakening g empty_env t1 c1 d11 @@ -327,6 +356,7 @@ let (k_intro_exists : uu___2))) uu___2))) uu___1))))) + uu___))) uu___))) uu___))) uu___))) uu___) let (intro_exists : @@ -354,14 +384,14 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (77)) (Prims.of_int (10)) - (Prims.of_int (77)) (Prims.of_int (41))))) + (Prims.of_int (78)) (Prims.of_int (10)) + (Prims.of_int (78)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (77)) (Prims.of_int (44)) - (Prims.of_int (314)) (Prims.of_int (6))))) + (Prims.of_int (78)) (Prims.of_int (44)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Typing_Env.fresh @@ -376,17 +406,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (78)) + (Prims.of_int (79)) (Prims.of_int (11)) - (Prims.of_int (78)) + (Prims.of_int (79)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (78)) + (Prims.of_int (79)) (Prims.of_int (32)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -399,17 +429,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (80)) + (Prims.of_int (81)) (Prims.of_int (4)) - (Prims.of_int (84)) + (Prims.of_int (85)) (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (85)) + (Prims.of_int (86)) (Prims.of_int (6)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -446,17 +476,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (89)) + (Prims.of_int (90)) (Prims.of_int (105)) - (Prims.of_int (98)) + (Prims.of_int (99)) (Prims.of_int (18))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (100)) + (Prims.of_int (101)) (Prims.of_int (37)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -496,17 +526,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (102)) + (Prims.of_int (103)) (Prims.of_int (4)) - (Prims.of_int (111)) + (Prims.of_int (112)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (112)) + (Prims.of_int (113)) (Prims.of_int (6)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -559,17 +589,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (113)) + (Prims.of_int (114)) (Prims.of_int (16)) - (Prims.of_int (113)) + (Prims.of_int (114)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (113)) + (Prims.of_int (114)) (Prims.of_int (33)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (Obj.magic (prover @@ -586,17 +616,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (56)) - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (73))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (117)) + (Prims.of_int (118)) (Prims.of_int (76)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -613,17 +643,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (118)) + (Prims.of_int (119)) (Prims.of_int (13)) - (Prims.of_int (118)) + (Prims.of_int (119)) (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (119)) + (Prims.of_int (120)) (Prims.of_int (2)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (Obj.magic (Pulse_Checker_Prover_Substs.ss_to_nt_substs @@ -640,17 +670,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (119)) + (Prims.of_int (120)) (Prims.of_int (2)) - (Prims.of_int (119)) - (Prims.of_int (74))))) + (Prims.of_int (120)) + (Prims.of_int (111))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (119)) - (Prims.of_int (75)) - (Prims.of_int (314)) + (Prims.of_int (120)) + (Prims.of_int (112)) + (Prims.of_int (315)) (Prims.of_int (6))))) (if FStar_Pervasives_Native.uu___is_None @@ -661,7 +691,7 @@ let (intro_exists : (Pulse_Typing_Env.fail pst_sub1.Pulse_Checker_Prover_Base.pg FStar_Pervasives_Native.None - "intro exists ss not well-typed")) + "resulted substitution after intro exists protocol is not well-typed")) else Obj.magic (Obj.repr @@ -679,17 +709,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (122)) + (Prims.of_int (123)) (Prims.of_int (16)) - (Prims.of_int (122)) + (Prims.of_int (123)) (Prims.of_int (20))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (119)) - (Prims.of_int (75)) - (Prims.of_int (314)) + (Prims.of_int (120)) + (Prims.of_int (112)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -710,17 +740,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (128)) + (Prims.of_int (129)) (Prims.of_int (4)) - (Prims.of_int (128)) + (Prims.of_int (129)) (Prims.of_int (80))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (130)) + (Prims.of_int (131)) (Prims.of_int (48)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -737,17 +767,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (59)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (89))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (92)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -764,17 +794,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (48)) - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (96))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (99)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -791,17 +821,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (143)) + (Prims.of_int (144)) (Prims.of_int (4)) - (Prims.of_int (143)) + (Prims.of_int (144)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (143)) + (Prims.of_int (144)) (Prims.of_int (16)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -817,17 +847,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (150)) + (Prims.of_int (151)) (Prims.of_int (4)) - (Prims.of_int (150)) + (Prims.of_int (151)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (150)) + (Prims.of_int (151)) (Prims.of_int (50)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -869,17 +899,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (157)) + (Prims.of_int (158)) (Prims.of_int (4)) - (Prims.of_int (157)) + (Prims.of_int (158)) (Prims.of_int (22))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (159)) + (Prims.of_int (160)) (Prims.of_int (84)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -896,17 +926,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (160)) + (Prims.of_int (161)) (Prims.of_int (16)) - (Prims.of_int (160)) + (Prims.of_int (161)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (161)) + (Prims.of_int (162)) (Prims.of_int (94)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -926,17 +956,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (168)) + (Prims.of_int (169)) (Prims.of_int (4)) - (Prims.of_int (168)) + (Prims.of_int (169)) (Prims.of_int (22))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (168)) + (Prims.of_int (169)) (Prims.of_int (25)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -953,17 +983,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (177)) + (Prims.of_int (178)) (Prims.of_int (4)) - (Prims.of_int (177)) + (Prims.of_int (178)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (177)) + (Prims.of_int (178)) (Prims.of_int (50)) - (Prims.of_int (314)) + (Prims.of_int (315)) (Prims.of_int (6))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1025,17 +1055,17 @@ let (intro_exists : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (187)) + (Prims.of_int (188)) (Prims.of_int (4)) - (Prims.of_int (196)) + (Prims.of_int (197)) (Prims.of_int (16))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroExists.fst" - (Prims.of_int (302)) + (Prims.of_int (303)) (Prims.of_int (4)) - (Prims.of_int (311)) + (Prims.of_int (312)) (Prims.of_int (26))))) (Obj.magic (k_intro_exists diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroPure.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroPure.ml index 1634e2805..0de07b2d0 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroPure.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_IntroPure.ml @@ -28,7 +28,7 @@ let (k_intro_pure : (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" (Prims.of_int (25)) (Prims.of_int (34)) - (Prims.of_int (58)) (Prims.of_int (30))))) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_Typing.wr @@ -49,7 +49,7 @@ let (k_intro_pure : (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" (Prims.of_int (26)) (Prims.of_int (30)) - (Prims.of_int (58)) (Prims.of_int (30))))) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_Typing.comp_intro_pure p)) (fun uu___ -> @@ -70,7 +70,7 @@ let (k_intro_pure : "Pulse.Checker.Prover.IntroPure.fst" (Prims.of_int (27)) (Prims.of_int (54)) - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -94,7 +94,7 @@ let (k_intro_pure : "Pulse.Checker.Prover.IntroPure.fst" (Prims.of_int (32)) (Prims.of_int (30)) - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -107,26 +107,53 @@ let (k_intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (37)) - (Prims.of_int (4)) - (Prims.of_int (37)) - (Prims.of_int (58))))) + (Prims.of_int (34)) + (Prims.of_int (15)) + (Prims.of_int (34)) + (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (44)) - (Prims.of_int (20)) - (Prims.of_int (58)) + (Prims.of_int (34)) + (Prims.of_int (47)) + (Prims.of_int (59)) (Prims.of_int (30))))) - (Obj.magic - (Pulse_Checker_Base.continuation_elaborator_with_bind - g frame c t - d1 () x)) - (fun k -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - fun + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Syntax_Base.mk_ppname_no_range + "_pintrop")) + (fun uu___ -> + (fun ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.IntroPure.fst" + (Prims.of_int (38)) + (Prims.of_int (4)) + (Prims.of_int (38)) + (Prims.of_int (68))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.IntroPure.fst" + (Prims.of_int (45)) + (Prims.of_int (20)) + (Prims.of_int (59)) + (Prims.of_int (30))))) + (Obj.magic + (Pulse_Checker_Base.continuation_elaborator_with_bind + g frame c + t d1 () + (ppname, + x))) + (fun k -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___ -> + fun post_hint -> fun r -> @@ -135,17 +162,17 @@ let (k_intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (45)) + (Prims.of_int (46)) (Prims.of_int (25)) - (Prims.of_int (45)) + (Prims.of_int (46)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (44)) + (Prims.of_int (45)) (Prims.of_int (20)) - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -167,17 +194,17 @@ let (k_intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (46)) + (Prims.of_int (47)) (Prims.of_int (31)) - (Prims.of_int (46)) + (Prims.of_int (47)) (Prims.of_int (33))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (46)) + (Prims.of_int (47)) (Prims.of_int (36)) - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -193,17 +220,17 @@ let (k_intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (47)) + (Prims.of_int (48)) (Prims.of_int (18)) - (Prims.of_int (47)) + (Prims.of_int (48)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (50)) + (Prims.of_int (51)) + (Prims.of_int (59)) (Prims.of_int (59)) - (Prims.of_int (58)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -222,22 +249,22 @@ let (k_intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (52)) + (Prims.of_int (53)) (Prims.of_int (4)) - (Prims.of_int (56)) + (Prims.of_int (57)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (2)) - (Prims.of_int (58)) + (Prims.of_int (59)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> - Pulse_Checker_Prover_Util.st_typing_weakening + Pulse_Typing_Metatheory.st_typing_weakening g empty_env t1 c1 d12 @@ -276,8 +303,8 @@ let (k_intro_pure : uu___2))) uu___2))) uu___1))))) - uu___))) uu___))) uu___))) - uu___) + uu___))) uu___))) + uu___))) uu___))) uu___) let (is_eq2_uvar : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> @@ -327,14 +354,14 @@ let rec (try_collect_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (99)) (Prims.of_int (12)) - (Prims.of_int (99)) (Prims.of_int (34))))) + (Prims.of_int (100)) (Prims.of_int (12)) + (Prims.of_int (100)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (101)) (Prims.of_int (6)) - (Prims.of_int (118)) (Prims.of_int (26))))) + (Prims.of_int (102)) (Prims.of_int (6)) + (Prims.of_int (119)) (Prims.of_int (26))))) (Obj.magic (FStar_Reflection_V2_Formula.term_as_formula' rt)) (fun uu___ -> @@ -348,17 +375,17 @@ let rec (try_collect_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (104)) + (Prims.of_int (105)) (Prims.of_int (18)) - (Prims.of_int (104)) + (Prims.of_int (105)) (Prims.of_int (75))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (104)) + (Prims.of_int (105)) (Prims.of_int (78)) - (Prims.of_int (110)) + (Prims.of_int (111)) (Prims.of_int (21))))) (Obj.magic (try_collect_substs uvs @@ -372,17 +399,17 @@ let rec (try_collect_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (105)) + (Prims.of_int (106)) (Prims.of_int (18)) - (Prims.of_int (105)) + (Prims.of_int (106)) (Prims.of_int (75))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (106)) + (Prims.of_int (107)) (Prims.of_int (8)) - (Prims.of_int (110)) + (Prims.of_int (111)) (Prims.of_int (21))))) (Obj.magic (try_collect_substs @@ -442,14 +469,14 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (129)) (Prims.of_int (13)) - (Prims.of_int (129)) (Prims.of_int (23))))) + (Prims.of_int (130)) (Prims.of_int (13)) + (Prims.of_int (130)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (131)) (Prims.of_int (2)) - (Prims.of_int (262)) (Prims.of_int (14))))) + (Prims.of_int (132)) (Prims.of_int (2)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Checker_Prover_Base.op_Array_Access @@ -462,14 +489,14 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (131)) (Prims.of_int (2)) - (Prims.of_int (134)) (Prims.of_int (30))))) + (Prims.of_int (132)) (Prims.of_int (2)) + (Prims.of_int (135)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (134)) (Prims.of_int (31)) - (Prims.of_int (262)) (Prims.of_int (14))))) + (Prims.of_int (135)) (Prims.of_int (31)) + (Prims.of_int (263)) (Prims.of_int (14))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover pst.Pulse_Checker_Prover_Base.pg @@ -479,17 +506,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (6)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (29))))) (Obj.magic (Pulse_Typing_Env.env_to_string @@ -502,17 +529,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (132)) + (Prims.of_int (133)) (Prims.of_int (4)) - (Prims.of_int (134)) + (Prims.of_int (135)) (Prims.of_int (29))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -520,9 +547,9 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (133)) + (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (133)) + (Prims.of_int (134)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic @@ -561,17 +588,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (137)) + (Prims.of_int (138)) (Prims.of_int (12)) - (Prims.of_int (137)) + (Prims.of_int (138)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (51)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (Obj.magic (try_collect_substs @@ -585,17 +612,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (139)) + (Prims.of_int (140)) (Prims.of_int (15)) - (Prims.of_int (139)) + (Prims.of_int (140)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (140)) + (Prims.of_int (141)) (Prims.of_int (38)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -610,17 +637,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (142)) + (Prims.of_int (143)) (Prims.of_int (13)) - (Prims.of_int (142)) + (Prims.of_int (143)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (142)) + (Prims.of_int (143)) (Prims.of_int (26)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -634,17 +661,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (143)) + (Prims.of_int (144)) (Prims.of_int (9)) - (Prims.of_int (145)) + (Prims.of_int (146)) (Prims.of_int (7))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (145)) + (Prims.of_int (146)) (Prims.of_int (10)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -652,17 +679,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (144)) + (Prims.of_int (145)) (Prims.of_int (12)) - (Prims.of_int (144)) + (Prims.of_int (145)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (145)) + (Prims.of_int (146)) (Prims.of_int (4)) - (Prims.of_int (145)) + (Prims.of_int (146)) (Prims.of_int (7))))) (Obj.magic (Pulse_Checker_Pure.core_check_term_with_expected_type @@ -683,17 +710,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (146)) + (Prims.of_int (147)) (Prims.of_int (16)) - (Prims.of_int (146)) + (Prims.of_int (147)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (146)) + (Prims.of_int (147)) (Prims.of_int (52)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (Obj.magic (Pulse_Checker_Pure.check_prop_validity @@ -710,17 +737,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (179)) + (Prims.of_int (180)) (Prims.of_int (10)) - (Prims.of_int (179)) + (Prims.of_int (180)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (179)) + (Prims.of_int (180)) (Prims.of_int (44)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -738,17 +765,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (181)) + (Prims.of_int (182)) (Prims.of_int (19)) - (Prims.of_int (181)) + (Prims.of_int (182)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (181)) + (Prims.of_int (182)) (Prims.of_int (46)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -768,17 +795,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (182)) + (Prims.of_int (183)) (Prims.of_int (21)) - (Prims.of_int (182)) + (Prims.of_int (183)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (182)) + (Prims.of_int (183)) (Prims.of_int (33)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -795,17 +822,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (186)) + (Prims.of_int (187)) (Prims.of_int (96)) - (Prims.of_int (220)) + (Prims.of_int (221)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (2)) - (Prims.of_int (262)) + (Prims.of_int (263)) (Prims.of_int (14))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -813,17 +840,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (187)) + (Prims.of_int (188)) (Prims.of_int (16)) - (Prims.of_int (187)) + (Prims.of_int (188)) (Prims.of_int (89))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (187)) + (Prims.of_int (188)) (Prims.of_int (92)) - (Prims.of_int (220)) + (Prims.of_int (221)) (Prims.of_int (29))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -846,17 +873,17 @@ let (intro_pure : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (192)) + (Prims.of_int (193)) (Prims.of_int (6)) - (Prims.of_int (192)) + (Prims.of_int (193)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.IntroPure.fst" - (Prims.of_int (220)) + (Prims.of_int (221)) (Prims.of_int (4)) - (Prims.of_int (220)) + (Prims.of_int (221)) (Prims.of_int (29))))) (Obj.magic (k_intro_pure diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Match.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Match.ml index b6a133e78..f91a41ba7 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Match.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Match.ml @@ -577,13 +577,13 @@ let rec (unify : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (231)) (Prims.of_int (4)) - (Prims.of_int (232)) (Prims.of_int (18))))) + (Prims.of_int (201)) (Prims.of_int (4)) + (Prims.of_int (202)) (Prims.of_int (18))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (233)) (Prims.of_int (4)) - (Prims.of_int (341)) (Prims.of_int (27))))) + (Prims.of_int (203)) (Prims.of_int (4)) + (Prims.of_int (311)) (Prims.of_int (27))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> fun g1 -> @@ -597,14 +597,14 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (235)) (Prims.of_int (11)) - (Prims.of_int (235)) (Prims.of_int (12))))) + (Prims.of_int (205)) (Prims.of_int (11)) + (Prims.of_int (205)) (Prims.of_int (12))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (235)) (Prims.of_int (15)) - (Prims.of_int (341)) (Prims.of_int (27))))) + (Prims.of_int (205)) (Prims.of_int (15)) + (Prims.of_int (311)) (Prims.of_int (27))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> q)) (fun uu___ -> (fun q0 -> @@ -614,17 +614,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (236)) + (Prims.of_int (206)) (Prims.of_int (10)) - (Prims.of_int (236)) + (Prims.of_int (206)) (Prims.of_int (16))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (239)) + (Prims.of_int (209)) (Prims.of_int (2)) - (Prims.of_int (341)) + (Prims.of_int (311)) (Prims.of_int (27))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> @@ -638,17 +638,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (239)) + (Prims.of_int (209)) (Prims.of_int (2)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (93))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (242)) + (Prims.of_int (212)) (Prims.of_int (2)) - (Prims.of_int (341)) + (Prims.of_int (311)) (Prims.of_int (27))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -659,17 +659,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (72)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (4)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (92))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -682,17 +682,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (4)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (4)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (92))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -700,9 +700,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (51)) - (Prims.of_int (240)) + (Prims.of_int (210)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic @@ -749,17 +749,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (244)) + (Prims.of_int (214)) (Prims.of_int (4)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (102))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (248)) + (Prims.of_int (218)) (Prims.of_int (4)) - (Prims.of_int (248)) + (Prims.of_int (218)) (Prims.of_int (33))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -771,17 +771,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (81)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (101))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -796,17 +796,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -814,9 +814,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (60)) - (Prims.of_int (245)) + (Prims.of_int (215)) (Prims.of_int (80))))) (FStar_Sealed.seal (Obj.magic @@ -871,17 +871,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (10)) - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (7)) - (Prims.of_int (341)) + (Prims.of_int (311)) (Prims.of_int (27))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -889,17 +889,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (14)) - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (10)) - (Prims.of_int (250)) + (Prims.of_int (220)) (Prims.of_int (37))))) (Obj.magic (contains_uvar @@ -922,17 +922,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (252)) + (Prims.of_int (222)) (Prims.of_int (7)) - (Prims.of_int (252)) + (Prims.of_int (222)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (252)) + (Prims.of_int (222)) (Prims.of_int (4)) - (Prims.of_int (267)) + (Prims.of_int (237)) (Prims.of_int (13))))) (Obj.magic (eligible_for_smt_equality @@ -949,17 +949,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (254)) + (Prims.of_int (224)) (Prims.of_int (11)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (146))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (257)) + (Prims.of_int (227)) (Prims.of_int (62)) - (Prims.of_int (262)) + (Prims.of_int (232)) (Prims.of_int (26))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -971,17 +971,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (125)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (145))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (13)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (145))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -996,17 +996,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (13)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (145))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (13)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (145))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1014,9 +1014,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (104)) - (Prims.of_int (255)) + (Prims.of_int (225)) (Prims.of_int (124))))) (FStar_Sealed.seal (Obj.magic @@ -1062,17 +1062,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (258)) + (Prims.of_int (228)) (Prims.of_int (18)) - (Prims.of_int (258)) + (Prims.of_int (228)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (258)) + (Prims.of_int (228)) (Prims.of_int (32)) - (Prims.of_int (262)) + (Prims.of_int (232)) (Prims.of_int (26))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1089,17 +1089,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (259)) + (Prims.of_int (229)) (Prims.of_int (18)) - (Prims.of_int (259)) + (Prims.of_int (229)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (260)) + (Prims.of_int (230)) (Prims.of_int (9)) - (Prims.of_int (262)) + (Prims.of_int (232)) (Prims.of_int (26))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1116,17 +1116,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (260)) + (Prims.of_int (230)) (Prims.of_int (15)) - (Prims.of_int (260)) + (Prims.of_int (230)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (260)) + (Prims.of_int (230)) (Prims.of_int (9)) - (Prims.of_int (262)) + (Prims.of_int (232)) (Prims.of_int (26))))) (Obj.magic (FStar_Tactics_V2_Builtins.check_equiv @@ -1166,17 +1166,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (264)) + (Prims.of_int (234)) (Prims.of_int (11)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (150))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (267)) + (Prims.of_int (237)) (Prims.of_int (9)) - (Prims.of_int (267)) + (Prims.of_int (237)) (Prims.of_int (13))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -1188,17 +1188,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (129)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (149))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (13)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (149))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1213,17 +1213,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (13)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (149))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (13)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (149))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1231,9 +1231,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (108)) - (Prims.of_int (265)) + (Prims.of_int (235)) (Prims.of_int (128))))) (FStar_Sealed.seal (Obj.magic @@ -1296,17 +1296,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (271)) + (Prims.of_int (241)) (Prims.of_int (9)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (151))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (152)) - (Prims.of_int (289)) + (Prims.of_int (259)) (Prims.of_int (18))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -1318,17 +1318,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (130)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (150))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (13)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (150))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1343,17 +1343,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (13)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (150))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (13)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (150))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1361,9 +1361,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (109)) - (Prims.of_int (272)) + (Prims.of_int (242)) (Prims.of_int (129))))) (FStar_Sealed.seal (Obj.magic @@ -1409,17 +1409,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (273)) + (Prims.of_int (243)) (Prims.of_int (17)) - (Prims.of_int (273)) + (Prims.of_int (243)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (276)) + (Prims.of_int (246)) (Prims.of_int (54)) - (Prims.of_int (289)) + (Prims.of_int (259)) (Prims.of_int (18))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1435,17 +1435,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (277)) + (Prims.of_int (247)) (Prims.of_int (22)) - (Prims.of_int (277)) + (Prims.of_int (247)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (280)) + (Prims.of_int (250)) (Prims.of_int (59)) - (Prims.of_int (289)) + (Prims.of_int (259)) (Prims.of_int (18))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1463,17 +1463,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (281)) + (Prims.of_int (251)) (Prims.of_int (19)) - (Prims.of_int (281)) + (Prims.of_int (251)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (284)) + (Prims.of_int (254)) (Prims.of_int (54)) - (Prims.of_int (289)) + (Prims.of_int (259)) (Prims.of_int (18))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -1490,17 +1490,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (285)) + (Prims.of_int (255)) (Prims.of_int (20)) - (Prims.of_int (285)) + (Prims.of_int (255)) (Prims.of_int (91))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (284)) + (Prims.of_int (254)) (Prims.of_int (54)) - (Prims.of_int (289)) + (Prims.of_int (259)) (Prims.of_int (18))))) (Obj.magic (FStar_Tactics_V2_Builtins.check_equiv @@ -1559,17 +1559,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (293)) + (Prims.of_int (263)) (Prims.of_int (11)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (124))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (305)) + (Prims.of_int (275)) (Prims.of_int (11)) - (Prims.of_int (305)) + (Prims.of_int (275)) (Prims.of_int (41))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -1581,17 +1581,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (103)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (123))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (13)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (123))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1606,17 +1606,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (13)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (123))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (13)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (123))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1624,9 +1624,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (82)) - (Prims.of_int (294)) + (Prims.of_int (264)) (Prims.of_int (102))))) (FStar_Sealed.seal (Obj.magic @@ -1697,17 +1697,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (309)) + (Prims.of_int (279)) (Prims.of_int (13)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (127))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (128)) - (Prims.of_int (318)) + (Prims.of_int (288)) (Prims.of_int (29))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -1719,17 +1719,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (106)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (126))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (15)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (126))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1744,17 +1744,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (15)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (126))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (15)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (126))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1762,9 +1762,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (85)) - (Prims.of_int (310)) + (Prims.of_int (280)) (Prims.of_int (105))))) (FStar_Sealed.seal (Obj.magic @@ -1810,17 +1810,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (311)) + (Prims.of_int (281)) (Prims.of_int (21)) - (Prims.of_int (311)) + (Prims.of_int (281)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (312)) + (Prims.of_int (282)) (Prims.of_int (13)) - (Prims.of_int (318)) + (Prims.of_int (288)) (Prims.of_int (29))))) (Obj.magic (unify g @@ -1881,17 +1881,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (323)) + (Prims.of_int (293)) (Prims.of_int (15)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (125))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (326)) + (Prims.of_int (296)) (Prims.of_int (15)) - (Prims.of_int (340)) + (Prims.of_int (310)) (Prims.of_int (18))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -1903,17 +1903,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (104)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (124))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (17)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (124))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1928,17 +1928,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (17)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (124))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (17)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (124))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1946,9 +1946,9 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (83)) - (Prims.of_int (324)) + (Prims.of_int (294)) (Prims.of_int (103))))) (FStar_Sealed.seal (Obj.magic @@ -2011,17 +2011,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (328)) + (Prims.of_int (298)) (Prims.of_int (25)) - (Prims.of_int (328)) + (Prims.of_int (298)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (329)) + (Prims.of_int (299)) (Prims.of_int (17)) - (Prims.of_int (339)) + (Prims.of_int (309)) (Prims.of_int (28))))) (Obj.magic (unify g @@ -2047,17 +2047,17 @@ let rec (unify : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (331)) + (Prims.of_int (301)) (Prims.of_int (27)) - (Prims.of_int (331)) + (Prims.of_int (301)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (332)) + (Prims.of_int (302)) (Prims.of_int (19)) - (Prims.of_int (338)) + (Prims.of_int (308)) (Prims.of_int (32))))) (Obj.magic (unify g @@ -2134,13 +2134,13 @@ let (try_match_pq : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (347)) (Prims.of_int (10)) - (Prims.of_int (347)) (Prims.of_int (34))))) + (Prims.of_int (317)) (Prims.of_int (10)) + (Prims.of_int (317)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (348)) (Prims.of_int (2)) - (Prims.of_int (352)) (Prims.of_int (27))))) + (Prims.of_int (318)) (Prims.of_int (2)) + (Prims.of_int (322)) (Prims.of_int (27))))) (Obj.magic (unify g uvs p q Pulse_Checker_Prover_Substs.empty)) (fun r -> FStar_Tactics_Effect.lift_div_tac @@ -2178,14 +2178,14 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (363)) (Prims.of_int (11)) - (Prims.of_int (363)) (Prims.of_int (21))))) + (Prims.of_int (333)) (Prims.of_int (11)) + (Prims.of_int (333)) (Prims.of_int (21))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (364)) (Prims.of_int (52)) - (Prims.of_int (427)) (Prims.of_int (11))))) + (Prims.of_int (334)) (Prims.of_int (52)) + (Prims.of_int (397)) (Prims.of_int (11))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Checker_Prover_Base.op_Array_Access @@ -2198,16 +2198,16 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (366)) + (Prims.of_int (336)) (Prims.of_int (11)) - (Prims.of_int (366)) + (Prims.of_int (336)) (Prims.of_int (45))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (368)) Prims.int_zero - (Prims.of_int (427)) + (Prims.of_int (338)) Prims.int_zero + (Prims.of_int (397)) (Prims.of_int (11))))) (Obj.magic (try_match_pq @@ -2221,17 +2221,17 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (368)) + (Prims.of_int (338)) Prims.int_zero - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (372)) + (Prims.of_int (342)) Prims.int_zero - (Prims.of_int (427)) + (Prims.of_int (397)) (Prims.of_int (11))))) (Obj.magic (Pulse_Checker_Prover_Util.debug_prover @@ -2242,17 +2242,17 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (369)) + (Prims.of_int (339)) (Prims.of_int (2)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (91))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (369)) + (Prims.of_int (339)) (Prims.of_int (2)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (91))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2260,17 +2260,17 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (25)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (369)) + (Prims.of_int (339)) (Prims.of_int (2)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (91))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -2284,18 +2284,18 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (369)) + (Prims.of_int (339)) (Prims.of_int (2)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (91))))) ( FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (369)) + (Prims.of_int (339)) (Prims.of_int (2)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (91))))) ( Obj.magic @@ -2304,9 +2304,9 @@ let (match_step : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Match.fst" - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (4)) - (Prims.of_int (370)) + (Prims.of_int (340)) (Prims.of_int (24))))) (FStar_Sealed.seal (Obj.magic diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Substs.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Substs.ml index f9ac25a50..80aee0d62 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Substs.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Substs.ml @@ -126,7 +126,7 @@ let rec (ss_env : Pulse_Typing_Env.env -> ss_t -> Pulse_Typing_Env.env) = | [] -> g | y::tl -> ss_env - (Pulse_Typing_Metatheory.subst_env g + (Pulse_Typing_Env.subst_env g [Pulse_Syntax_Naming.NT (y, (FStar_Map.sel ss.m y))]) (tail ss) type nt_substs = Pulse_Syntax_Naming.subst_elt Prims.list @@ -168,8 +168,7 @@ let (nt_subst_env : fun ss -> let g' = FStar_List_Tot_Base.fold_left - (fun g1 -> fun elt -> Pulse_Typing_Metatheory.subst_env g1 [elt]) g - ss in + (fun g1 -> fun elt -> Pulse_Typing_Env.subst_env g1 [elt]) g ss in g' type ('g, 'uvs, 'nts) well_typed_nt_substs = Obj.t type ('nts, 'ss) is_permutation = Obj.t @@ -203,14 +202,14 @@ let rec (ss_to_nt_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (255)) (Prims.of_int (26)) - (Prims.of_int (255)) (Prims.of_int (44))))) + (Prims.of_int (254)) (Prims.of_int (26)) + (Prims.of_int (254)) (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (254)) (Prims.of_int (8)) - (Prims.of_int (268)) (Prims.of_int (13))))) + (Prims.of_int (253)) (Prims.of_int (8)) + (Prims.of_int (267)) (Prims.of_int (13))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Typing_Env.remove_binding uvs)) @@ -227,17 +226,17 @@ let rec (ss_to_nt_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (257)) + (Prims.of_int (256)) (Prims.of_int (17)) - (Prims.of_int (257)) + (Prims.of_int (256)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (257)) + (Prims.of_int (256)) (Prims.of_int (34)) - (Prims.of_int (267)) + (Prims.of_int (266)) (Prims.of_int (19))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -250,17 +249,17 @@ let rec (ss_to_nt_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (258)) + (Prims.of_int (257)) (Prims.of_int (37)) - (Prims.of_int (258)) + (Prims.of_int (257)) (Prims.of_int (45))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (259)) + (Prims.of_int (258)) (Prims.of_int (48)) - (Prims.of_int (267)) + (Prims.of_int (266)) (Prims.of_int (19))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -273,22 +272,22 @@ let rec (ss_to_nt_substs : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (261)) + (Prims.of_int (260)) (Prims.of_int (11)) - (Prims.of_int (262)) + (Prims.of_int (261)) (Prims.of_int (82))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" - (Prims.of_int (263)) + (Prims.of_int (262)) (Prims.of_int (9)) - (Prims.of_int (267)) + (Prims.of_int (266)) (Prims.of_int (19))))) (Obj.magic (ss_to_nt_substs g - (Pulse_Typing_Metatheory.subst_env + (Pulse_Typing_Env.subst_env rest_uvs [ Pulse_Syntax_Naming.NT @@ -353,9 +352,9 @@ let rec (well_typed_nt_substs_prefix : | (Pulse_Syntax_Naming.NT (y, e))::nts_rest -> (Pulse_Syntax_Naming.NT (y, e)) :: (well_typed_nt_substs_prefix g - (Pulse_Typing_Metatheory.subst_env rest_uvs + (Pulse_Typing_Env.subst_env rest_uvs [Pulse_Syntax_Naming.NT (y, e)]) nts_rest - (Pulse_Typing_Metatheory.subst_env rest_uvs1 + (Pulse_Typing_Env.subst_env rest_uvs1 [Pulse_Syntax_Naming.NT (y, e)]))))) let rec (st_typing_nt_substs : Pulse_Typing_Env.env -> @@ -384,19 +383,60 @@ let rec (st_typing_nt_substs : | (Pulse_Syntax_Naming.NT (uu___3, e))::nts_rest -> let t_typing1 = coerce_eq t_typing () in let t_typing2 = - Pulse_Typing_Metatheory.st_typing_subst g x - ty (Pulse_Typing_Env.push_env uvs_rest g') - e () t c t_typing1 in + Pulse_Typing_Metatheory_Base.st_typing_subst + g x ty + (Pulse_Typing_Env.push_env uvs_rest g') e + () t c t_typing1 in st_typing_nt_substs g - (Pulse_Typing_Metatheory.subst_env uvs_rest + (Pulse_Typing_Env.subst_env uvs_rest [Pulse_Syntax_Naming.NT (x, e)]) - (Pulse_Typing_Metatheory.subst_env g' + (Pulse_Typing_Env.subst_env g' [Pulse_Syntax_Naming.NT (x, e)]) (Pulse_Syntax_Naming.subst_st_term t [Pulse_Syntax_Naming.NT (x, e)]) (Pulse_Syntax_Naming.subst_comp c [Pulse_Syntax_Naming.NT (x, e)]) t_typing2 nts_rest)) +let (st_typing_subst : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_term -> + Pulse_Syntax_Base.comp_st -> + (unit, unit, unit) Pulse_Typing.st_typing -> + ss_t -> + ((unit, unit, unit) Pulse_Typing.st_typing + FStar_Pervasives_Native.option, + unit) FStar_Tactics_Effect.tac_repr) + = + fun g -> + fun uvs -> + fun t -> + fun c -> + fun d -> + fun ss -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" + (Prims.of_int (334)) (Prims.of_int (16)) + (Prims.of_int (334)) (Prims.of_int (40))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Prover.Substs.fst" + (Prims.of_int (335)) (Prims.of_int (2)) + (Prims.of_int (342)) (Prims.of_int (10))))) + (Obj.magic (ss_to_nt_substs g uvs ss)) + (fun nts_opt -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + match nts_opt with + | FStar_Pervasives_Native.None -> + FStar_Pervasives_Native.None + | FStar_Pervasives_Native.Some nts -> + FStar_Pervasives_Native.Some + (st_typing_nt_substs g uvs + (Pulse_Typing_Env.mk_env + (Pulse_Typing_Env.fstar_env g)) t c d nts))) let (st_typing_nt_substs_derived : Pulse_Typing_Env.env -> Pulse_Typing_Env.env -> diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Util.ml b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Util.ml index 421eb0c04..69bbd6f84 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Prover_Util.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Prover_Util.ml @@ -1,100 +1,4 @@ open Prims -let (st_typing_subst : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp_st -> - (unit, unit, unit) Pulse_Typing.st_typing -> - Pulse_Checker_Prover_Substs.ss_t -> - ((unit, unit, unit) Pulse_Typing.st_typing - FStar_Pervasives_Native.option, - unit) FStar_Tactics_Effect.tac_repr) - = - fun g -> - fun uvs -> - fun t -> - fun c -> - fun d -> - fun ss -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.Util.fst" - (Prims.of_int (16)) (Prims.of_int (16)) - (Prims.of_int (16)) (Prims.of_int (43))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Prover.Util.fst" - (Prims.of_int (17)) (Prims.of_int (2)) - (Prims.of_int (24)) (Prims.of_int (10))))) - (Obj.magic - (Pulse_Checker_Prover_Substs.ss_to_nt_substs g uvs ss)) - (fun nts_opt -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - match nts_opt with - | FStar_Pervasives_Native.None -> - FStar_Pervasives_Native.None - | FStar_Pervasives_Native.Some nts -> - FStar_Pervasives_Native.Some - (Pulse_Checker_Prover_Substs.st_typing_nt_substs - g uvs - (Pulse_Typing_Env.mk_env - (Pulse_Typing_Env.fstar_env g)) t c d nts))) -let (st_typing_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.st_typing -> - Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) - = - fun g -> - fun g' -> - fun t -> - fun c -> - fun d -> - fun g1 -> - let g2 = Pulse_Typing_Env.diff g1 g in - let d1 = - Pulse_Typing_Metatheory.st_typing_weakening g g' t c d g2 in - d1 -let (st_typing_weakening_standard : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.st_typing -> - Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) - = - fun g -> - fun t -> - fun c -> - fun d -> - fun g1 -> - let g' = Pulse_Typing_Env.mk_env (Pulse_Typing_Env.fstar_env g) in - let d1 = st_typing_weakening g g' t c d g1 in d1 -let (st_typing_weakening_end : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.st_typing -> - Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) - = - fun g -> - fun g' -> - fun t -> - fun c -> - fun d -> - fun g'' -> - let g2 = Pulse_Typing_Env.diff g'' g' in - let emp_env = - Pulse_Typing_Env.mk_env (Pulse_Typing_Env.fstar_env g) in - let d1 = - Pulse_Typing_Metatheory.st_typing_weakening - (Pulse_Typing_Env.push_env g g') emp_env t c - (FStar_Pervasives.coerce_eq () d) g2 in - FStar_Pervasives.coerce_eq () d1 let (debug_prover : Pulse_Typing_Env.env -> (unit -> (Prims.string, unit) FStar_Tactics_Effect.tac_repr) -> @@ -102,7 +6,34 @@ let (debug_prover : = fun uu___1 -> fun uu___ -> - (fun uu___ -> - fun uu___1 -> - Obj.magic (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> ()))) + (fun g -> + fun s -> + if + Pulse_RuntimeUtils.debug_at_level (Pulse_Typing_Env.fstar_env g) + "prover" + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.Util.fst" + (Prims.of_int (7)) (Prims.of_int (15)) + (Prims.of_int (7)) (Prims.of_int (21))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Prover.Util.fst" + (Prims.of_int (7)) (Prims.of_int (7)) + (Prims.of_int (7)) (Prims.of_int (21))))) + (Obj.magic (s ())) + (fun uu___ -> + (fun uu___ -> + Obj.magic (FStar_Tactics_V2_Builtins.print uu___)) + uu___))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> ())))) uu___1 uu___ \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Return.ml b/src/ocaml/plugin/generated/Pulse_Checker_Return.ml index e77328dad..5c29c781c 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Return.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Return.ml @@ -4,167 +4,175 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun ctxt -> fun ctxt_typing -> fun post_hint -> - fun st -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (20)) (Prims.of_int (10)) - (Prims.of_int (20)) (Prims.of_int (48))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (20)) (Prims.of_int (51)) - (Prims.of_int (60)) (Prims.of_int (56))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "check_return" - st.Pulse_Syntax_Base.range2 g)) - (fun uu___ -> - (fun g1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (21)) (Prims.of_int (53)) - (Prims.of_int (21)) (Prims.of_int (60))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (20)) (Prims.of_int (51)) - (Prims.of_int (60)) (Prims.of_int (56))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> st.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_Return - { Pulse_Syntax_Base.ctag = c; - Pulse_Syntax_Base.insert_eq = use_eq; - Pulse_Syntax_Base.term = t;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (28)) - (Prims.of_int (4)) - (Prims.of_int (37)) - (Prims.of_int (48))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (21)) - (Prims.of_int (63)) - (Prims.of_int (60)) - (Prims.of_int (56))))) - (match post_hint with - | FStar_Pervasives_Native.None -> - Obj.magic - (Pulse_Checker_Pure.check_term_and_type - g1 t) - | FStar_Pervasives_Native.Some post - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (31)) - (Prims.of_int (23)) - (Prims.of_int (31)) - (Prims.of_int (68))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (30)) - (Prims.of_int (18)) - (Prims.of_int (37)) - (Prims.of_int (48))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_with_expected_type - g1 t - post.Pulse_Typing.ret_ty)) - (fun uu___1 -> - FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - match uu___1 with - | Prims.Mkdtuple2 - (t1, d) -> - FStar_Pervasives.Mkdtuple5 - (t1, - (post.Pulse_Typing.u), - (post.Pulse_Typing.ret_ty), - (), d))))) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | FStar_Pervasives.Mkdtuple5 - (t1, u, ty, uty, d) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (38)) - (Prims.of_int (4)) - (Prims.of_int (60)) - (Prims.of_int (56))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Return.fst" - (Prims.of_int (38)) - (Prims.of_int (4)) - (Prims.of_int (60)) - (Prims.of_int (56))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___2 -> - uu___1)) - (fun uu___2 -> - (fun uu___2 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + fun res_ppname -> + fun st -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Return.fst" + (Prims.of_int (21)) (Prims.of_int (10)) + (Prims.of_int (21)) (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Return.fst" + (Prims.of_int (21)) (Prims.of_int (51)) + (Prims.of_int (63)) (Prims.of_int (76))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "check_return" + st.Pulse_Syntax_Base.range2 g)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (22)) (Prims.of_int (53)) + (Prims.of_int (22)) (Prims.of_int (60))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (21)) (Prims.of_int (51)) + (Prims.of_int (63)) (Prims.of_int (76))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> st.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_Return + { Pulse_Syntax_Base.ctag = c; + Pulse_Syntax_Base.insert_eq = use_eq; + Pulse_Syntax_Base.term = t;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (29)) + (Prims.of_int (4)) + (Prims.of_int (38)) + (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (22)) + (Prims.of_int (63)) + (Prims.of_int (63)) + (Prims.of_int (76))))) + (match post_hint with + | FStar_Pervasives_Native.None -> + Obj.magic + (Pulse_Checker_Pure.check_term_and_type + g1 t) + | FStar_Pervasives_Native.Some + post -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (32)) + (Prims.of_int (23)) + (Prims.of_int (32)) + (Prims.of_int (68))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (31)) + (Prims.of_int (18)) + (Prims.of_int (38)) + (Prims.of_int (48))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_with_expected_type + g1 t + post.Pulse_Typing.ret_ty)) + (fun uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + match uu___1 with + | Prims.Mkdtuple2 + (t1, d) -> + FStar_Pervasives.Mkdtuple5 + (t1, + ( + post.Pulse_Typing.u), + ( + post.Pulse_Typing.ret_ty), + (), d))))) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | FStar_Pervasives.Mkdtuple5 + (t1, u, ty, uty, d) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (39)) + (Prims.of_int (4)) + (Prims.of_int (63)) + (Prims.of_int (76))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Return.fst" + (Prims.of_int (39)) + (Prims.of_int (4)) + (Prims.of_int (63)) + (Prims.of_int (76))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + uu___1)) + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (40)) + (Prims.of_int (41)) (Prims.of_int (10)) - (Prims.of_int (40)) + (Prims.of_int (41)) (Prims.of_int (17))))) - (FStar_Sealed.seal + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (40)) + (Prims.of_int (41)) (Prims.of_int (20)) - (Prims.of_int (60)) - (Prims.of_int (56))))) - (FStar_Tactics_Effect.lift_div_tac + (Prims.of_int (63)) + (Prims.of_int (76))))) + ( + FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> Pulse_Typing_Env.fresh g1)) - (fun uu___3 - -> + ( + fun + uu___3 -> (fun x -> Obj.magic (FStar_Tactics_Effect.tac_bind @@ -172,23 +180,23 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (11)) - (Prims.of_int (41)) - (Prims.of_int (20))))) + (Prims.of_int (42)) + (Prims.of_int (24))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (41)) - (Prims.of_int (23)) - (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (42)) + (Prims.of_int (27)) + (Prims.of_int (63)) + (Prims.of_int (76))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> - Pulse_Syntax_Base.v_as_nv - x)) + (res_ppname, + x))) (fun uu___3 -> (fun px @@ -199,18 +207,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (43)) + (Prims.of_int (44)) (Prims.of_int (6)) - (Prims.of_int (55)) + (Prims.of_int (58)) (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (41)) - (Prims.of_int (23)) - (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (42)) + (Prims.of_int (27)) + (Prims.of_int (63)) + (Prims.of_int (76))))) (match post_hint with | @@ -222,17 +230,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (45)) + (Prims.of_int (46)) (Prims.of_int (26)) - (Prims.of_int (45)) + (Prims.of_int (46)) (Prims.of_int (102))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (44)) + (Prims.of_int (45)) (Prims.of_int (15)) - (Prims.of_int (46)) + (Prims.of_int (47)) (Prims.of_int (21))))) (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type @@ -264,17 +272,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (50)) + (Prims.of_int (51)) (Prims.of_int (33)) - (Prims.of_int (50)) + (Prims.of_int (51)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (51)) + (Prims.of_int (52)) (Prims.of_int (8)) - (Prims.of_int (55)) + (Prims.of_int (58)) (Prims.of_int (60))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -295,7 +303,7 @@ let (check : (Pulse_Typing_Env.fail g1 FStar_Pervasives_Native.None - "Unexpected variable clash in return")) + "check_return: unexpected variable clash in return post,please file a bug report")) else Obj.magic (Obj.repr @@ -324,18 +332,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (57)) - (Prims.of_int (2)) (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (2)) + (Prims.of_int (63)) + (Prims.of_int (76))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (57)) - (Prims.of_int (65)) (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (65)) + (Prims.of_int (63)) + (Prims.of_int (76))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -350,18 +358,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (58)) + (Prims.of_int (61)) (Prims.of_int (13)) - (Prims.of_int (58)) + (Prims.of_int (61)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (58)) + (Prims.of_int (61)) (Prims.of_int (40)) - (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (63)) + (Prims.of_int (76))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> @@ -378,18 +386,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (10)) - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (60)) + (Prims.of_int (63)) (Prims.of_int (2)) - (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (63)) + (Prims.of_int (76))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> @@ -410,18 +418,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (60)) - (Prims.of_int (9)) - (Prims.of_int (60)) - (Prims.of_int (38))))) + (Prims.of_int (63)) + (Prims.of_int (18)) + (Prims.of_int (63)) + (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Return.fst" - (Prims.of_int (60)) + (Prims.of_int (63)) (Prims.of_int (2)) - (Prims.of_int (60)) - (Prims.of_int (56))))) + (Prims.of_int (63)) + (Prims.of_int (76))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g ctxt () @@ -439,13 +447,14 @@ let (check : c use_eq u ty t1 post x) - d1)) + d1 + res_ppname)) (fun uu___5 -> (fun uu___5 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g ctxt uu___5 post_hint @@ -457,5 +466,5 @@ let (check : uu___3))) uu___3))) uu___3))) - uu___2))) uu___1))) - uu___))) uu___) \ No newline at end of file + uu___2))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_Rewrite.ml b/src/ocaml/plugin/generated/Pulse_Checker_Rewrite.ml index 5357037bb..020763ed9 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_Rewrite.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_Rewrite.ml @@ -4,128 +4,130 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (21)) (Prims.of_int (10)) - (Prims.of_int (21)) (Prims.of_int (48))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (21)) (Prims.of_int (51)) - (Prims.of_int (43)) (Prims.of_int (54))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "check_rewrite" - t.Pulse_Syntax_Base.range2 g)) - (fun uu___ -> - (fun g1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (22)) (Prims.of_int (32)) - (Prims.of_int (22)) (Prims.of_int (38))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (21)) (Prims.of_int (51)) - (Prims.of_int (43)) (Prims.of_int (54))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_Rewrite - { Pulse_Syntax_Base.t1 = p; - Pulse_Syntax_Base.t2 = q;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (23)) - (Prims.of_int (26)) - (Prims.of_int (23)) - (Prims.of_int (41))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (22)) - (Prims.of_int (41)) - (Prims.of_int (43)) - (Prims.of_int (54))))) - (Obj.magic - (Pulse_Checker_Pure.check_vprop g1 - p)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 - (p1, p_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (24)) - (Prims.of_int (26)) - (Prims.of_int (24)) - (Prims.of_int (41))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.Rewrite.fst" - (Prims.of_int (23)) - (Prims.of_int (44)) - (Prims.of_int (43)) - (Prims.of_int (54))))) - (Obj.magic - (Pulse_Checker_Pure.check_vprop - g1 q)) - (fun uu___2 -> - (fun uu___2 -> - match uu___2 - with - | Prims.Mkdtuple2 - (q1, - q_typing) - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" + (Prims.of_int (22)) (Prims.of_int (10)) + (Prims.of_int (22)) (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" + (Prims.of_int (22)) (Prims.of_int (51)) + (Prims.of_int (44)) (Prims.of_int (74))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "check_rewrite" + t.Pulse_Syntax_Base.range2 g)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (23)) (Prims.of_int (32)) + (Prims.of_int (23)) (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (22)) (Prims.of_int (51)) + (Prims.of_int (44)) (Prims.of_int (74))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_Rewrite + { Pulse_Syntax_Base.t1 = p; + Pulse_Syntax_Base.t2 = q;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (24)) + (Prims.of_int (26)) + (Prims.of_int (24)) + (Prims.of_int (41))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (23)) + (Prims.of_int (41)) + (Prims.of_int (44)) + (Prims.of_int (74))))) + (Obj.magic + (Pulse_Checker_Pure.check_vprop + g1 p)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 + (p1, p_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (25)) + (Prims.of_int (26)) + (Prims.of_int (25)) + (Prims.of_int (41))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.Rewrite.fst" + (Prims.of_int (24)) + (Prims.of_int (44)) + (Prims.of_int (44)) + (Prims.of_int (74))))) + (Obj.magic + (Pulse_Checker_Pure.check_vprop + g1 q)) + (fun uu___2 -> + (fun uu___2 -> + match uu___2 + with + | Prims.Mkdtuple2 + (q1, + q_typing) + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (26)) + (Prims.of_int (27)) (Prims.of_int (6)) - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (33)) - (Prims.of_int (43)) - (Prims.of_int (54))))) + (Prims.of_int (44)) + (Prims.of_int (74))))) (if Pulse_Syntax_Base.eq_tm p1 q1 @@ -144,17 +146,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (28)) + (Prims.of_int (29)) (Prims.of_int (24)) - (Prims.of_int (28)) + (Prims.of_int (29)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (28)) + (Prims.of_int (29)) (Prims.of_int (38)) - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -171,17 +173,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (29)) + (Prims.of_int (30)) (Prims.of_int (24)) - (Prims.of_int (29)) + (Prims.of_int (30)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (29)) + (Prims.of_int (30)) (Prims.of_int (38)) - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (30))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -198,17 +200,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (30)) + (Prims.of_int (31)) (Prims.of_int (29)) - (Prims.of_int (30)) + (Prims.of_int (31)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (29)) + (Prims.of_int (30)) (Prims.of_int (38)) - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_V2_Builtins.check_equiv @@ -232,17 +234,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (31)) + (Prims.of_int (32)) (Prims.of_int (11)) - (Prims.of_int (31)) + (Prims.of_int (32)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (32)) + (Prims.of_int (33)) (Prims.of_int (11)) - (Prims.of_int (41)) + (Prims.of_int (42)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_V2_Builtins.log_issues @@ -263,17 +265,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (34)) + (Prims.of_int (35)) (Prims.of_int (13)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -281,17 +283,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (27)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_V2_Builtins.term_to_string @@ -306,17 +308,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -324,17 +326,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (38)) + (Prims.of_int (39)) (Prims.of_int (27)) - (Prims.of_int (38)) + (Prims.of_int (39)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_V2_Builtins.term_to_string @@ -349,17 +351,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -367,17 +369,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (37)) + (Prims.of_int (38)) (Prims.of_int (27)) - (Prims.of_int (37)) + (Prims.of_int (38)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -392,17 +394,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (35)) + (Prims.of_int (36)) (Prims.of_int (20)) - (Prims.of_int (39)) + (Prims.of_int (40)) (Prims.of_int (53))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -410,9 +412,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (36)) + (Prims.of_int (37)) (Prims.of_int (27)) - (Prims.of_int (36)) + (Prims.of_int (37)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic @@ -510,18 +512,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (42)) + (Prims.of_int (43)) (Prims.of_int (9)) - (Prims.of_int (42)) + (Prims.of_int (43)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (43)) + (Prims.of_int (44)) Prims.int_one - (Prims.of_int (43)) - (Prims.of_int (54))))) + (Prims.of_int (44)) + (Prims.of_int (74))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -538,18 +540,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (43)) - (Prims.of_int (8)) - (Prims.of_int (43)) - (Prims.of_int (36))))) + (Prims.of_int (44)) + (Prims.of_int (17)) + (Prims.of_int (44)) + (Prims.of_int (56))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.Rewrite.fst" - (Prims.of_int (43)) + (Prims.of_int (44)) Prims.int_one - (Prims.of_int (43)) - (Prims.of_int (54))))) + (Prims.of_int (44)) + (Prims.of_int (74))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -562,13 +564,14 @@ let (check : = q1 })) (Pulse_Typing.comp_rewrite - p1 q1) d)) + p1 q1) d + res_ppname)) (fun uu___3 -> (fun uu___3 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___3 post_hint @@ -576,5 +579,5 @@ let (check : uu___3))) uu___3))) uu___3))) - uu___2))) uu___1))) - uu___))) uu___) \ No newline at end of file + uu___2))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_STApp.ml b/src/ocaml/plugin/generated/Pulse_Checker_STApp.ml index 309bebffd..b3a65a837 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_STApp.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_STApp.ml @@ -65,7 +65,7 @@ let rec (intro_uvars_for_logical_implicits : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" (Prims.of_int (45)) (Prims.of_int (2)) - (Prims.of_int (59)) (Prims.of_int (82))))) + (Prims.of_int (63)) (Prims.of_int (31))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_Syntax_Pure.is_arrow ty)) (fun uu___ -> @@ -225,9 +225,50 @@ let rec (intro_uvars_for_logical_implicits : uu___))) uu___)) | uu___ -> Obj.magic - (Pulse_Typing_Env.fail g FStar_Pervasives_Native.None - "intro_uvars_for_logical_implicits in stapp, unexpected type")) - uu___) + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (61)) (Prims.of_int (6)) + (Prims.of_int (63)) (Prims.of_int (31))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (60)) (Prims.of_int (4)) + (Prims.of_int (63)) (Prims.of_int (31))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (63)) + (Prims.of_int (9)) + (Prims.of_int (63)) + (Prims.of_int (30))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string ty)) + (fun uu___1 -> + FStar_Tactics_Effect.lift_div_tac + (fun uu___2 -> + Prims.strcat + "check_stapp.intro_uvars_for_logical_implicits: expected an arrow type,with an implicit parameter, found: " + (Prims.strcat uu___1 ""))))) + (fun uu___1 -> + (fun uu___1 -> + Obj.magic + (Pulse_Typing_Env.fail g + FStar_Pervasives_Native.None uu___1)) + uu___1))) uu___) let (instantaite_implicits : Pulse_Typing_Env.env -> Pulse_Syntax_Base.st_term -> @@ -241,13 +282,13 @@ let (instantaite_implicits : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (66)) (Prims.of_int (14)) (Prims.of_int (66)) + (Prims.of_int (71)) (Prims.of_int (14)) (Prims.of_int (71)) (Prims.of_int (21))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (66)) (Prims.of_int (24)) (Prims.of_int (79)) - (Prims.of_int (72))))) + (Prims.of_int (71)) (Prims.of_int (24)) (Prims.of_int (87)) + (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> t.Pulse_Syntax_Base.range2)) (fun uu___ -> @@ -257,13 +298,13 @@ let (instantaite_implicits : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (67)) (Prims.of_int (46)) - (Prims.of_int (67)) (Prims.of_int (52))))) + (Prims.of_int (72)) (Prims.of_int (46)) + (Prims.of_int (72)) (Prims.of_int (52))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (66)) (Prims.of_int (24)) - (Prims.of_int (79)) (Prims.of_int (72))))) + (Prims.of_int (71)) (Prims.of_int (24)) + (Prims.of_int (87)) (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> t.Pulse_Syntax_Base.term1)) (fun uu___ -> @@ -280,18 +321,18 @@ let (instantaite_implicits : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (68)) + (Prims.of_int (73)) (Prims.of_int (17)) - (Prims.of_int (68)) + (Prims.of_int (73)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (68)) + (Prims.of_int (73)) (Prims.of_int (44)) - (Prims.of_int (79)) - (Prims.of_int (72))))) + (Prims.of_int (87)) + (Prims.of_int (32))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> Pulse_Syntax_Pure.tm_pureapp head @@ -304,18 +345,18 @@ let (instantaite_implicits : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (69)) + (Prims.of_int (74)) (Prims.of_int (14)) - (Prims.of_int (69)) + (Prims.of_int (74)) (Prims.of_int (51))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (68)) + (Prims.of_int (73)) (Prims.of_int (44)) - (Prims.of_int (79)) - (Prims.of_int (72))))) + (Prims.of_int (87)) + (Prims.of_int (32))))) (Obj.magic (Pulse_Checker_Pure.instantiate_term_implicits g pure_app)) @@ -382,10 +423,64 @@ let (instantaite_implicits : }))) | uu___3 -> Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (86)) + (Prims.of_int (8)) + (Prims.of_int (87)) + (Prims.of_int (32))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (85)) + (Prims.of_int (6)) + (Prims.of_int (87)) + (Prims.of_int (32))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (87)) + (Prims.of_int (11)) + (Prims.of_int (87)) + (Prims.of_int (31))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + t1)) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + Prims.strcat + "check_stapp.instantiate_implicits: expected an application term, found: " + (Prims.strcat + uu___4 ""))))) + (fun + uu___4 -> + (fun + uu___4 -> + Obj.magic (Pulse_Typing_Env.fail g - FStar_Pervasives_Native.None - "instantiate_implicits in stapp, unexpected term"))))) + (FStar_Pervasives_Native.Some + (t1.Pulse_Syntax_Base.range1)) + uu___4)) + uu___4)))))) uu___1))) uu___1))) uu___))) uu___) let (check : @@ -393,130 +488,137 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g0 -> fun ctxt -> fun ctxt_typing -> fun post_hint -> - fun t -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (90)) (Prims.of_int (11)) - (Prims.of_int (90)) (Prims.of_int (43))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (90)) (Prims.of_int (46)) - (Prims.of_int (135)) (Prims.of_int (123))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "st_app" - t.Pulse_Syntax_Base.range2 g0)) - (fun uu___ -> - (fun g01 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (91)) (Prims.of_int (14)) - (Prims.of_int (91)) (Prims.of_int (21))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (91)) (Prims.of_int (24)) - (Prims.of_int (135)) (Prims.of_int (123))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.range2)) - (fun uu___ -> - (fun range -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (93)) - (Prims.of_int (24)) - (Prims.of_int (93)) - (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (91)) - (Prims.of_int (24)) - (Prims.of_int (135)) - (Prims.of_int (123))))) - (Obj.magic (instantaite_implicits g01 t)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | FStar_Pervasives.Mkdtuple3 - (uvs, g, t1) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (95)) - (Prims.of_int (46)) - (Prims.of_int (95)) - (Prims.of_int (52))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.STApp.fst" - (Prims.of_int (93)) - (Prims.of_int (53)) - (Prims.of_int (135)) - (Prims.of_int (123))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___1 -> - t1.Pulse_Syntax_Base.term1)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Pulse_Syntax_Base.Tm_STApp - { - Pulse_Syntax_Base.head - = head; - Pulse_Syntax_Base.arg_qual - = qual; - Pulse_Syntax_Base.arg - = arg;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal + fun res_ppname -> + fun t -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.STApp.fst" + (Prims.of_int (99)) (Prims.of_int (11)) + (Prims.of_int (99)) (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.STApp.fst" + (Prims.of_int (99)) (Prims.of_int (46)) + (Prims.of_int (144)) (Prims.of_int (123))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "st_app" + t.Pulse_Syntax_Base.range2 g0)) + (fun uu___ -> + (fun g01 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (100)) (Prims.of_int (14)) + (Prims.of_int (100)) (Prims.of_int (21))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (100)) (Prims.of_int (24)) + (Prims.of_int (144)) (Prims.of_int (123))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.range2)) + (fun uu___ -> + (fun range -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (102)) + (Prims.of_int (24)) + (Prims.of_int (102)) + (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (100)) + (Prims.of_int (24)) + (Prims.of_int (144)) + (Prims.of_int (123))))) + (Obj.magic + (instantaite_implicits g01 t)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | FStar_Pervasives.Mkdtuple3 + (uvs, g, t1) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (104)) + (Prims.of_int (46)) + (Prims.of_int (104)) + (Prims.of_int (52))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.STApp.fst" + (Prims.of_int (102)) + (Prims.of_int (53)) + (Prims.of_int (144)) + (Prims.of_int (123))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___1 -> + t1.Pulse_Syntax_Base.term1)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Pulse_Syntax_Base.Tm_STApp + { + Pulse_Syntax_Base.head + = head; + Pulse_Syntax_Base.arg_qual + = qual; + Pulse_Syntax_Base.arg + = arg;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (96)) + (Prims.of_int (105)) (Prims.of_int (35)) - (Prims.of_int (96)) + (Prims.of_int (105)) (Prims.of_int (52))))) - (FStar_Sealed.seal + ( + FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (95)) + (Prims.of_int (104)) (Prims.of_int (55)) - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (123))))) - (Obj.magic + ( + Obj.magic (Pulse_Checker_Pure.check_term g head)) - (fun uu___2 - -> + ( + fun + uu___2 -> (fun uu___2 -> match uu___2 @@ -532,17 +634,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (97)) + (Prims.of_int (106)) (Prims.of_int (2)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (102)) + (Prims.of_int (111)) (Prims.of_int (2)) - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (123))))) (Obj.magic (debug_log @@ -554,17 +656,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (12)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (4)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (42))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -572,17 +674,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (15)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (12)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (42))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -597,17 +699,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (12)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (12)) - (Prims.of_int (100)) + (Prims.of_int (109)) (Prims.of_int (42))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -615,9 +717,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (15)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic @@ -684,17 +786,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (105)) + (Prims.of_int (114)) (Prims.of_int (4)) - (Prims.of_int (107)) + (Prims.of_int (116)) (Prims.of_int (46))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (112)) + (Prims.of_int (121)) (Prims.of_int (4)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (debug_log @@ -706,17 +808,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (106)) + (Prims.of_int (115)) (Prims.of_int (14)) - (Prims.of_int (107)) + (Prims.of_int (116)) (Prims.of_int (45))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (106)) + (Prims.of_int (115)) (Prims.of_int (6)) - (Prims.of_int (107)) + (Prims.of_int (116)) (Prims.of_int (45))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -724,9 +826,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (107)) + (Prims.of_int (116)) (Prims.of_int (17)) - (Prims.of_int (107)) + (Prims.of_int (116)) (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic @@ -771,17 +873,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (114)) + (Prims.of_int (123)) (Prims.of_int (28)) - (Prims.of_int (114)) + (Prims.of_int (123)) (Prims.of_int (70))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (113)) + (Prims.of_int (122)) (Prims.of_int (8)) - (Prims.of_int (129)) + (Prims.of_int (138)) (Prims.of_int (126))))) (Obj.magic (Pulse_Checker_Pure.check_term_with_expected_type @@ -808,18 +910,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (10)) - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (68))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (71)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -840,18 +942,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (16)) - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (43)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -880,22 +982,24 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (16)) - (Prims.of_int (123)) - (Prims.of_int (56))))) + (Prims.of_int (132)) + (Prims.of_int (18)) + (Prims.of_int (132)) + (Prims.of_int (67))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (59)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (132)) + (Prims.of_int (72)) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> - Pulse_Typing.wr + { + Pulse_Syntax_Base.term1 + = (Pulse_Syntax_Base.Tm_STApp { Pulse_Syntax_Base.head @@ -904,7 +1008,10 @@ let (check : = qual; Pulse_Syntax_Base.arg = arg1 - }))) + }); + Pulse_Syntax_Base.range2 + = range + })) (fun uu___6 -> (fun t2 @@ -915,18 +1022,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (16)) - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (61)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -943,18 +1050,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (34)) - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -969,29 +1076,30 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) - (Prims.of_int (22)) - (Prims.of_int (127)) - (Prims.of_int (66))))) + (Prims.of_int (136)) + (Prims.of_int (31)) + (Prims.of_int (136)) + (Prims.of_int (86))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre_uvs g0 ctxt () uvs t2 - c d2)) + c d2 + res_ppname)) (fun uu___6 -> (fun uu___6 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g0 ctxt uu___6 post_hint @@ -1012,18 +1120,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (10)) - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (68))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (71)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1044,18 +1152,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (16)) - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (43)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1084,22 +1192,24 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (16)) - (Prims.of_int (123)) - (Prims.of_int (56))))) + (Prims.of_int (132)) + (Prims.of_int (18)) + (Prims.of_int (132)) + (Prims.of_int (67))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (59)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (132)) + (Prims.of_int (72)) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> - Pulse_Typing.wr + { + Pulse_Syntax_Base.term1 + = (Pulse_Syntax_Base.Tm_STApp { Pulse_Syntax_Base.head @@ -1108,7 +1218,10 @@ let (check : = qual; Pulse_Syntax_Base.arg = arg1 - }))) + }); + Pulse_Syntax_Base.range2 + = range + })) (fun uu___7 -> (fun t2 @@ -1119,18 +1232,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (16)) - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (61)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1147,18 +1260,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (34)) - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1173,29 +1286,30 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) - (Prims.of_int (22)) - (Prims.of_int (127)) - (Prims.of_int (66))))) + (Prims.of_int (136)) + (Prims.of_int (31)) + (Prims.of_int (136)) + (Prims.of_int (86))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre_uvs g0 ctxt () uvs t2 - c d2)) + c d2 + res_ppname)) (fun uu___7 -> (fun uu___7 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g0 ctxt uu___7 post_hint @@ -1216,18 +1330,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (10)) - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (68))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (121)) + (Prims.of_int (130)) (Prims.of_int (71)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1248,18 +1362,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (16)) - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (122)) + (Prims.of_int (131)) (Prims.of_int (43)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1288,22 +1402,24 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (16)) - (Prims.of_int (123)) - (Prims.of_int (56))))) + (Prims.of_int (132)) + (Prims.of_int (18)) + (Prims.of_int (132)) + (Prims.of_int (67))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (123)) - (Prims.of_int (59)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (132)) + (Prims.of_int (72)) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> - Pulse_Typing.wr + { + Pulse_Syntax_Base.term1 + = (Pulse_Syntax_Base.Tm_STApp { Pulse_Syntax_Base.head @@ -1312,7 +1428,10 @@ let (check : = qual; Pulse_Syntax_Base.arg = arg1 - }))) + }); + Pulse_Syntax_Base.range2 + = range + })) (fun uu___7 -> (fun t2 @@ -1323,18 +1442,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (16)) - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (58))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (124)) + (Prims.of_int (133)) (Prims.of_int (61)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1351,18 +1470,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (34)) - (Prims.of_int (125)) + (Prims.of_int (134)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> @@ -1377,29 +1496,30 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) - (Prims.of_int (22)) - (Prims.of_int (127)) - (Prims.of_int (66))))) + (Prims.of_int (136)) + (Prims.of_int (31)) + (Prims.of_int (136)) + (Prims.of_int (86))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (127)) + (Prims.of_int (136)) (Prims.of_int (8)) - (Prims.of_int (127)) - (Prims.of_int (84))))) + (Prims.of_int (136)) + (Prims.of_int (104))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre_uvs g0 ctxt () uvs t2 - c d2)) + c d2 + res_ppname)) (fun uu___7 -> (fun uu___7 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g0 ctxt uu___7 post_hint @@ -1426,17 +1546,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (9)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1444,17 +1564,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (16)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (38))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1469,17 +1589,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1487,17 +1607,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (132)) + (Prims.of_int (141)) (Prims.of_int (16)) - (Prims.of_int (132)) + (Prims.of_int (141)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string @@ -1512,17 +1632,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (130)) + (Prims.of_int (139)) (Prims.of_int (31)) - (Prims.of_int (133)) + (Prims.of_int (142)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1530,9 +1650,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (131)) + (Prims.of_int (140)) (Prims.of_int (16)) - (Prims.of_int (131)) + (Prims.of_int (140)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic @@ -1600,17 +1720,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (31)) - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (123))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (9)) - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (123))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1618,9 +1738,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.STApp.fst" - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (96)) - (Prims.of_int (135)) + (Prims.of_int (144)) (Prims.of_int (122))))) (FStar_Sealed.seal (Obj.magic @@ -1655,5 +1775,5 @@ let (check : uu___5))) uu___3))) uu___2))) - uu___1))) uu___))) - uu___))) uu___) \ No newline at end of file + uu___1))) uu___))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_While.ml b/src/ocaml/plugin/generated/Pulse_Checker_While.ml index c6ae10b66..351b8c601 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_While.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_While.ml @@ -5,7 +5,7 @@ let (while_cond_comp_typing : Pulse_Syntax_Base.ppname -> Pulse_Syntax_Base.term -> Pulse_Syntax_Base.term -> - unit -> (unit, unit) Pulse_Typing_Metatheory.comp_typing_u) + unit -> (unit, unit) Pulse_Typing_Metatheory_Base.comp_typing_u) = fun g -> fun u -> @@ -13,7 +13,7 @@ let (while_cond_comp_typing : fun ty -> fun inv_body -> fun inv_typing -> - Pulse_Typing_Metatheory.admit_comp_typing g + Pulse_Typing_Metatheory_Base.admit_comp_typing g (Pulse_Typing.comp_while_cond x inv_body) let (while_body_comp_typing : Pulse_Typing_Env.env -> @@ -21,7 +21,7 @@ let (while_body_comp_typing : Pulse_Syntax_Base.ppname -> Pulse_Syntax_Base.term -> Pulse_Syntax_Base.term -> - unit -> (unit, unit) Pulse_Typing_Metatheory.comp_typing_u) + unit -> (unit, unit) Pulse_Typing_Metatheory_Base.comp_typing_u) = fun g -> fun u -> @@ -29,170 +29,224 @@ let (while_body_comp_typing : fun ty -> fun inv_body -> fun inv_typing -> - Pulse_Typing_Metatheory.admit_comp_typing g + Pulse_Typing_Metatheory_Base.admit_comp_typing g (Pulse_Typing.comp_while_body x inv_body) let (check : Pulse_Typing_Env.env -> Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (33)) (Prims.of_int (10)) - (Prims.of_int (33)) (Prims.of_int (45))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (33)) (Prims.of_int (48)) - (Prims.of_int (99)) (Prims.of_int (70))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "while loop" - t.Pulse_Syntax_Base.range2 g)) - (fun uu___ -> - (fun g1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (34)) (Prims.of_int (72)) - (Prims.of_int (34)) (Prims.of_int (78))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (33)) (Prims.of_int (48)) - (Prims.of_int (99)) (Prims.of_int (70))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_While - { Pulse_Syntax_Base.invariant = inv; - Pulse_Syntax_Base.condition = cond; - Pulse_Syntax_Base.condition_var = - condition_var; - Pulse_Syntax_Base.body3 = body;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (36)) - (Prims.of_int (4)) - (Prims.of_int (37)) - (Prims.of_int (88))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (34)) - (Prims.of_int (81)) - (Prims.of_int (99)) - (Prims.of_int (70))))) - (Obj.magic - (Pulse_Checker_Pure.check_vprop - (Pulse_Checker_Pure.push_context - "invariant" - (Pulse_Syntax_Base.term_range - inv) g1) - (Pulse_Syntax_Base.tm_exists_sl - Pulse_Syntax_Pure.u0 - { - Pulse_Syntax_Base.binder_ty - = Pulse_Typing.tm_bool; - Pulse_Syntax_Base.binder_ppname - = condition_var - } inv))) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | Prims.Mkdtuple2 - (ex_inv, inv_typing) -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (40)) - (Prims.of_int (2)) - (Prims.of_int (41)) - (Prims.of_int (59))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.While.fst" - (Prims.of_int (41)) - (Prims.of_int (60)) - (Prims.of_int (99)) - (Prims.of_int (70))))) - (if - Prims.op_Negation - (Pulse_Syntax_Base.uu___is_Tm_ExistsSL - ex_inv.Pulse_Syntax_Base.t) - then - Obj.magic - (Obj.repr - (Pulse_Typing_Env.fail + fun res_ppname -> + fun t -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.While.fst" + (Prims.of_int (34)) (Prims.of_int (10)) + (Prims.of_int (34)) (Prims.of_int (45))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.While.fst" + (Prims.of_int (34)) (Prims.of_int (48)) + (Prims.of_int (108)) (Prims.of_int (70))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "while loop" + t.Pulse_Syntax_Base.range2 g)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (35)) (Prims.of_int (72)) + (Prims.of_int (35)) (Prims.of_int (78))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (34)) (Prims.of_int (48)) + (Prims.of_int (108)) + (Prims.of_int (70))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_While + { Pulse_Syntax_Base.invariant = inv; + Pulse_Syntax_Base.condition = cond; + Pulse_Syntax_Base.condition_var = + condition_var; + Pulse_Syntax_Base.body3 = body;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (37)) + (Prims.of_int (4)) + (Prims.of_int (38)) + (Prims.of_int (88))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (35)) + (Prims.of_int (81)) + (Prims.of_int (108)) + (Prims.of_int (70))))) + (Obj.magic + (Pulse_Checker_Pure.check_vprop + (Pulse_Checker_Pure.push_context + "invariant" + (Pulse_Syntax_Base.term_range + inv) g1) + (Pulse_Syntax_Base.tm_exists_sl + Pulse_Syntax_Pure.u0 + { + Pulse_Syntax_Base.binder_ty + = + Pulse_Typing.tm_bool; + Pulse_Syntax_Base.binder_ppname + = condition_var + } inv))) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 with + | Prims.Mkdtuple2 + (ex_inv, inv_typing) -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (41)) + (Prims.of_int (2)) + (Prims.of_int (44)) + (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (44)) + (Prims.of_int (39)) + (Prims.of_int (108)) + (Prims.of_int (70))))) + (if + Prims.op_Negation + (Pulse_Syntax_Base.uu___is_Tm_ExistsSL + ex_inv.Pulse_Syntax_Base.t) + then + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (43)) + (Prims.of_int (9)) + (Prims.of_int (44)) + (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (42)) + (Prims.of_int (7)) + (Prims.of_int (44)) + (Prims.of_int (38))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (44)) + (Prims.of_int (12)) + (Prims.of_int (44)) + (Prims.of_int (37))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + ex_inv)) + (fun + uu___2 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___3 -> + Prims.strcat + "check_while: typechecked invariant " + (Prims.strcat + uu___2 + " is not an existential"))))) + (fun + uu___2 -> + (fun + uu___2 -> + Obj.magic + (Pulse_Typing_Env.fail g1 - FStar_Pervasives_Native.None - "Typechecked invariant is not an exists")) - else - Obj.magic - (Obj.repr - (FStar_Tactics_Effect.lift_div_tac - ( - fun + (FStar_Pervasives_Native.Some + (t.Pulse_Syntax_Base.range2)) + uu___2)) + uu___2))) + else + Obj.magic + (Obj.repr + (FStar_Tactics_Effect.lift_div_tac + (fun uu___3 -> ())))) - (fun uu___2 -> - (fun uu___2 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - ( - FStar_Sealed.seal + (fun uu___2 -> + (fun uu___2 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (43)) + (Prims.of_int (46)) (Prims.of_int (59)) - (Prims.of_int (43)) + (Prims.of_int (46)) (Prims.of_int (67))))) - ( - FStar_Sealed.seal + (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (41)) - (Prims.of_int (60)) - (Prims.of_int (99)) + (Prims.of_int (44)) + (Prims.of_int (39)) + (Prims.of_int (108)) (Prims.of_int (70))))) - ( - FStar_Tactics_Effect.lift_div_tac + (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> ex_inv.Pulse_Syntax_Base.t)) - ( - fun + (fun uu___3 -> (fun uu___3 -> @@ -213,17 +267,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (45)) + (Prims.of_int (48)) (Prims.of_int (2)) - (Prims.of_int (47)) - (Prims.of_int (92))))) + (Prims.of_int (52)) + (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (47)) - (Prims.of_int (93)) - (Prims.of_int (99)) + (Prims.of_int (52)) + (Prims.of_int (35)) + (Prims.of_int (108)) (Prims.of_int (70))))) (if (Prims.op_Negation @@ -238,11 +292,65 @@ let (check : then Obj.magic (Obj.repr + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (51)) + (Prims.of_int (9)) + (Prims.of_int (52)) + (Prims.of_int (34))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (50)) + (Prims.of_int (7)) + (Prims.of_int (52)) + (Prims.of_int (34))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (52)) + (Prims.of_int (12)) + (Prims.of_int (52)) + (Prims.of_int (33))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + ty)) + (fun + uu___4 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___5 -> + Prims.strcat + "While loop invariant exists but its witness type is " + (Prims.strcat + uu___4 + ", expected bool"))))) + (fun + uu___4 -> + (fun + uu___4 -> + Obj.magic (Pulse_Typing_Env.fail g1 (FStar_Pervasives_Native.Some (nm.Pulse_Syntax_Base.range)) - "While loop invariant exists but its witness type is not bool")) + uu___4)) + uu___4))) else Obj.magic (Obj.repr @@ -260,17 +368,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (49)) + (Prims.of_int (54)) (Prims.of_int (31)) - (Prims.of_int (49)) + (Prims.of_int (54)) (Prims.of_int (76))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (49)) + (Prims.of_int (54)) (Prims.of_int (79)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -293,22 +401,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (51)) + (Prims.of_int (56)) (Prims.of_int (16)) - (Prims.of_int (51)) + (Prims.of_int (56)) (Prims.of_int (87))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (49)) + (Prims.of_int (54)) (Prims.of_int (79)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___5 -> - Pulse_Typing_Metatheory.st_comp_typing_inversion + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion (Pulse_Checker_Pure.push_context "invariant" (Pulse_Syntax_Base.term_range @@ -316,7 +424,7 @@ let (check : (Pulse_Syntax_Base.st_comp_of_comp (Pulse_Typing.comp_while_cond nm inv1)) - (Pulse_Typing_Metatheory.comp_typing_inversion + (Pulse_Typing_Metatheory_Base.comp_typing_inversion (Pulse_Checker_Pure.push_context "invariant" (Pulse_Syntax_Base.term_range @@ -343,17 +451,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (54)) + (Prims.of_int (59)) (Prims.of_int (4)) - (Prims.of_int (54)) + (Prims.of_int (59)) (Prims.of_int (53))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (55)) + (Prims.of_int (60)) (Prims.of_int (4)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -377,17 +485,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (57)) + (Prims.of_int (62)) (Prims.of_int (42)) - (Prims.of_int (64)) - (Prims.of_int (28))))) + (Prims.of_int (71)) + (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (55)) + (Prims.of_int (60)) (Prims.of_int (4)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -395,22 +503,49 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (58)) - (Prims.of_int (12)) (Prims.of_int (63)) - (Prims.of_int (10))))) + (Prims.of_int (17)) + (Prims.of_int (63)) + (Prims.of_int (46))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (63)) + (Prims.of_int (49)) + (Prims.of_int (71)) + (Prims.of_int (35))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___6 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_while_c")) + (fun + uu___6 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" (Prims.of_int (64)) + (Prims.of_int (12)) + (Prims.of_int (70)) + (Prims.of_int (10))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (71)) (Prims.of_int (4)) - (Prims.of_int (64)) - (Prims.of_int (28))))) + (Prims.of_int (71)) + (Prims.of_int (35))))) (Obj.magic (check1 (Pulse_Checker_Pure.push_context - "while condition" + "check_while_condition" cond.Pulse_Syntax_Base.range2 g1) (Pulse_Syntax_Base.comp_pre @@ -419,6 +554,7 @@ let (check : () (FStar_Pervasives_Native.Some while_cond_hint) + ppname cond)) (fun uu___6 -> @@ -426,14 +562,15 @@ let (check : Obj.magic (Pulse_Checker_Base.apply_checker_result_k (Pulse_Checker_Pure.push_context - "while condition" + "check_while_condition" cond.Pulse_Syntax_Base.range2 g1) (Pulse_Syntax_Base.comp_pre (Pulse_Typing.comp_while_cond nm inv1)) while_cond_hint - r)) + r ppname)) + uu___6))) uu___6))) (fun uu___6 -> @@ -459,17 +596,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (33)) - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (78))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (81)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -492,22 +629,22 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (70)) + (Prims.of_int (77)) (Prims.of_int (18)) - (Prims.of_int (70)) + (Prims.of_int (77)) (Prims.of_int (89))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (68)) + (Prims.of_int (75)) (Prims.of_int (81)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___7 -> - Pulse_Typing_Metatheory.st_comp_typing_inversion + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion (Pulse_Checker_Pure.push_context "invariant" (Pulse_Syntax_Base.term_range @@ -515,7 +652,7 @@ let (check : (Pulse_Syntax_Base.st_comp_of_comp (Pulse_Typing.comp_while_body nm inv1)) - (Pulse_Typing_Metatheory.comp_typing_inversion + (Pulse_Typing_Metatheory_Base.comp_typing_inversion (Pulse_Checker_Pure.push_context "invariant" (Pulse_Syntax_Base.term_range @@ -542,17 +679,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (73)) + (Prims.of_int (80)) (Prims.of_int (6)) - (Prims.of_int (73)) + (Prims.of_int (80)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (74)) + (Prims.of_int (81)) (Prims.of_int (6)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -576,17 +713,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (75)) - (Prims.of_int (44)) (Prims.of_int (82)) - (Prims.of_int (30))))) + (Prims.of_int (44)) + (Prims.of_int (91)) + (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (74)) + (Prims.of_int (81)) (Prims.of_int (6)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -594,22 +731,49 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (76)) + (Prims.of_int (83)) + (Prims.of_int (19)) + (Prims.of_int (83)) + (Prims.of_int (48))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (83)) + (Prims.of_int (51)) + (Prims.of_int (91)) + (Prims.of_int (37))))) + (FStar_Tactics_Effect.lift_div_tac + (fun + uu___8 -> + Pulse_Syntax_Base.mk_ppname_no_range + "_while_b")) + (fun + uu___8 -> + (fun + ppname -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.While.fst" + (Prims.of_int (84)) (Prims.of_int (14)) - (Prims.of_int (81)) + (Prims.of_int (90)) (Prims.of_int (12))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (82)) + (Prims.of_int (91)) (Prims.of_int (6)) - (Prims.of_int (82)) - (Prims.of_int (30))))) + (Prims.of_int (91)) + (Prims.of_int (37))))) (Obj.magic (check1 (Pulse_Checker_Pure.push_context - "while body" + "check_while_body" body.Pulse_Syntax_Base.range2 g1) (Pulse_Syntax_Base.comp_pre @@ -618,6 +782,7 @@ let (check : () (FStar_Pervasives_Native.Some while_post_hint) + ppname body)) (fun uu___8 -> @@ -625,14 +790,15 @@ let (check : Obj.magic (Pulse_Checker_Base.apply_checker_result_k (Pulse_Checker_Pure.push_context - "while body" + "check_while_body" body.Pulse_Syntax_Base.range2 g1) (Pulse_Syntax_Base.comp_pre (Pulse_Typing.comp_while_body nm inv1)) while_post_hint - r)) + r ppname)) + uu___8))) uu___8))) (fun uu___8 -> @@ -658,18 +824,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (85)) + (Prims.of_int (94)) (Prims.of_int (14)) - (Prims.of_int (85)) + (Prims.of_int (94)) (Prims.of_int (72))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (86)) + (Prims.of_int (95)) (Prims.of_int (6)) - (Prims.of_int (86)) - (Prims.of_int (59))))) + (Prims.of_int (95)) + (Prims.of_int (79))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___9 -> @@ -690,18 +856,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (86)) - (Prims.of_int (13)) - (Prims.of_int (86)) - (Prims.of_int (41))))) + (Prims.of_int (95)) + (Prims.of_int (22)) + (Prims.of_int (95)) + (Prims.of_int (61))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (86)) + (Prims.of_int (95)) (Prims.of_int (6)) - (Prims.of_int (86)) - (Prims.of_int (59))))) + (Prims.of_int (95)) + (Prims.of_int (79))))) (Obj.magic (Pulse_Checker_Prover.try_frame_pre g pre () @@ -720,13 +886,14 @@ let (check : })) (Pulse_Typing.comp_while Pulse_Syntax_Base.ppname_default - inv1) d)) + inv1) d + res_ppname)) (fun uu___9 -> (fun uu___9 -> Obj.magic - (Pulse_Checker_Prover.repack + (Pulse_Checker_Prover.prove_post_hint g pre uu___9 post_hint @@ -740,17 +907,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (88)) + (Prims.of_int (97)) (Prims.of_int (10)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (87)) + (Prims.of_int (96)) (Prims.of_int (9)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -758,17 +925,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (27)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (70))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (88)) + (Prims.of_int (97)) (Prims.of_int (10)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (Obj.magic (Pulse_Syntax_Printer.comp_to_string @@ -786,17 +953,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (88)) + (Prims.of_int (97)) (Prims.of_int (10)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (88)) + (Prims.of_int (97)) (Prims.of_int (10)) - (Prims.of_int (92)) + (Prims.of_int (101)) (Prims.of_int (71))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -804,9 +971,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (91)) + (Prims.of_int (100)) (Prims.of_int (27)) - (Prims.of_int (91)) + (Prims.of_int (100)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic @@ -868,17 +1035,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (95)) + (Prims.of_int (104)) (Prims.of_int (9)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (94)) + (Prims.of_int (103)) (Prims.of_int (7)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -886,17 +1053,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (26)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (95)) + (Prims.of_int (104)) (Prims.of_int (9)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (Obj.magic (Pulse_Syntax_Printer.comp_to_string @@ -912,17 +1079,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (95)) + (Prims.of_int (104)) (Prims.of_int (9)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (95)) + (Prims.of_int (104)) (Prims.of_int (9)) - (Prims.of_int (99)) + (Prims.of_int (108)) (Prims.of_int (70))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -930,9 +1097,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.While.fst" - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (26)) - (Prims.of_int (98)) + (Prims.of_int (107)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic @@ -985,5 +1152,5 @@ let (check : uu___5))) uu___4))) uu___3))) - uu___2))) - uu___1))) uu___))) uu___) \ No newline at end of file + uu___2))) + uu___1))) uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Checker_WithLocal.ml b/src/ocaml/plugin/generated/Pulse_Checker_WithLocal.ml index 0728f7d4d..1a4ee2400 100644 --- a/src/ocaml/plugin/generated/Pulse_Checker_WithLocal.ml +++ b/src/ocaml/plugin/generated/Pulse_Checker_WithLocal.ml @@ -26,145 +26,148 @@ let (check : Pulse_Syntax_Base.term -> unit -> unit Pulse_Typing.post_hint_opt -> - Pulse_Syntax_Base.st_term -> - Pulse_Checker_Base.check_t -> - ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, - unit) FStar_Tactics_Effect.tac_repr) + Pulse_Syntax_Base.ppname -> + Pulse_Syntax_Base.st_term -> + Pulse_Checker_Base.check_t -> + ((unit, unit, unit) Pulse_Checker_Base.checker_result_t, + unit) FStar_Tactics_Effect.tac_repr) = fun g -> fun pre -> fun pre_typing -> fun post_hint -> - fun t -> - fun check1 -> - FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (33)) (Prims.of_int (10)) - (Prims.of_int (33)) (Prims.of_int (50))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (33)) (Prims.of_int (53)) - (Prims.of_int (83)) (Prims.of_int (80))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - Pulse_Checker_Pure.push_context "check_withlocal" - t.Pulse_Syntax_Base.range2 g)) - (fun uu___ -> - (fun g1 -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (34)) (Prims.of_int (16)) - (Prims.of_int (34)) (Prims.of_int (42))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (34)) (Prims.of_int (47)) - (Prims.of_int (83)) (Prims.of_int (80))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - fun t0 -> - { - Pulse_Syntax_Base.term1 = t0; - Pulse_Syntax_Base.range2 = - (t.Pulse_Syntax_Base.range2) - })) - (fun uu___ -> - (fun wr -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (35)) - (Prims.of_int (54)) - (Prims.of_int (35)) - (Prims.of_int (60))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (34)) - (Prims.of_int (47)) - (Prims.of_int (83)) - (Prims.of_int (80))))) - (FStar_Tactics_Effect.lift_div_tac - (fun uu___ -> - t.Pulse_Syntax_Base.term1)) - (fun uu___ -> - (fun uu___ -> - match uu___ with - | Pulse_Syntax_Base.Tm_WithLocal - { - Pulse_Syntax_Base.binder1 = - binder; - Pulse_Syntax_Base.initializer1 - = init; - Pulse_Syntax_Base.body4 = - body;_} - -> - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (37)) - (Prims.of_int (4)) - (Prims.of_int (37)) - (Prims.of_int (30))))) - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (35)) - (Prims.of_int (63)) - (Prims.of_int (83)) - (Prims.of_int (80))))) - (Obj.magic - (Pulse_Checker_Pure.check_term_and_type - g1 init)) - (fun uu___1 -> - (fun uu___1 -> - match uu___1 with - | FStar_Pervasives.Mkdtuple5 - (init1, - init_u, - init_t, - init_t_typing, - init_typing) - -> - if - Pulse_Syntax_Base.eq_univ - init_u - Pulse_Syntax_Pure.u0 - then - Obj.magic - (FStar_Tactics_Effect.tac_bind - (FStar_Sealed.seal - (Obj.magic - (FStar_Range.mk_range - "Pulse.Checker.WithLocal.fst" - (Prims.of_int (40)) + fun res_ppname -> + fun t -> + fun check1 -> + FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" + (Prims.of_int (35)) (Prims.of_int (10)) + (Prims.of_int (35)) (Prims.of_int (50))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" + (Prims.of_int (35)) (Prims.of_int (53)) + (Prims.of_int (92)) (Prims.of_int (38))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + Pulse_Checker_Pure.push_context "check_withlocal" + t.Pulse_Syntax_Base.range2 g)) + (fun uu___ -> + (fun g1 -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (36)) (Prims.of_int (16)) + (Prims.of_int (36)) (Prims.of_int (42))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (36)) (Prims.of_int (47)) + (Prims.of_int (92)) (Prims.of_int (38))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + fun t0 -> + { + Pulse_Syntax_Base.term1 = t0; + Pulse_Syntax_Base.range2 = + (t.Pulse_Syntax_Base.range2) + })) + (fun uu___ -> + (fun wr -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (37)) + (Prims.of_int (54)) + (Prims.of_int (37)) + (Prims.of_int (60))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (36)) + (Prims.of_int (47)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (FStar_Tactics_Effect.lift_div_tac + (fun uu___ -> + t.Pulse_Syntax_Base.term1)) + (fun uu___ -> + (fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.Tm_WithLocal + { + Pulse_Syntax_Base.binder1 + = binder; + Pulse_Syntax_Base.initializer1 + = init; + Pulse_Syntax_Base.body4 = + body;_} + -> + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (39)) + (Prims.of_int (4)) + (Prims.of_int (39)) + (Prims.of_int (30))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (37)) + (Prims.of_int (63)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (Obj.magic + (Pulse_Checker_Pure.check_term_and_type + g1 init)) + (fun uu___1 -> + (fun uu___1 -> + match uu___1 + with + | FStar_Pervasives.Mkdtuple5 + (init1, + init_u, + init_t, + init_t_typing, + init_typing) + -> + if + Pulse_Syntax_Base.eq_univ + init_u + Pulse_Syntax_Pure.u0 + then + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (42)) (Prims.of_int (12)) - (Prims.of_int (40)) + (Prims.of_int (42)) (Prims.of_int (19))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (40)) + (Prims.of_int (42)) (Prims.of_int (22)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -179,18 +182,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (41)) + (Prims.of_int (43)) (Prims.of_int (13)) - (Prims.of_int (41)) + (Prims.of_int (43)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (42)) + (Prims.of_int (44)) (Prims.of_int (4)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> @@ -212,17 +215,17 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (34)) - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (119))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (9)) - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (119))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -230,9 +233,9 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (82)) - (Prims.of_int (43)) + (Prims.of_int (45)) (Prims.of_int (118))))) (FStar_Sealed.seal (Obj.magic @@ -273,18 +276,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (45)) + (Prims.of_int (47)) (Prims.of_int (17)) - (Prims.of_int (45)) + (Prims.of_int (47)) (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (45)) + (Prims.of_int (47)) (Prims.of_int (35)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -300,18 +303,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (46)) + (Prims.of_int (48)) (Prims.of_int (23)) - (Prims.of_int (46)) + (Prims.of_int (48)) (Prims.of_int (76))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (46)) + (Prims.of_int (48)) (Prims.of_int (79)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -331,18 +334,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (47)) + (Prims.of_int (49)) (Prims.of_int (21)) - (Prims.of_int (47)) + (Prims.of_int (49)) (Prims.of_int (65))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (47)) + (Prims.of_int (49)) (Prims.of_int (68)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -362,18 +365,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (48)) + (Prims.of_int (50)) (Prims.of_int (28)) - (Prims.of_int (48)) + (Prims.of_int (50)) (Prims.of_int (74))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (48)) + (Prims.of_int (50)) (Prims.of_int (77)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___3 -> @@ -389,18 +392,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (52)) - (Prims.of_int (8)) (Prims.of_int (54)) + (Prims.of_int (8)) + (Prims.of_int (56)) (Prims.of_int (103))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (56)) + (Prims.of_int (58)) (Prims.of_int (6)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (match post_hint with | @@ -435,7 +438,7 @@ let (check : (Pulse_Typing_Env.fail g1 FStar_Pervasives_Native.None - "Unexpected name clash in with_local") + "Impossible! check_withlocal: unexpected name clash in with_local,please file a bug-report") else Obj.magic (FStar_Tactics_Effect.tac_bind @@ -443,18 +446,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (24)) - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (69)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___4 -> @@ -472,36 +475,36 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (60)) + (Prims.of_int (63)) (Prims.of_int (52)) - (Prims.of_int (62)) - (Prims.of_int (34))))) + (Prims.of_int (66)) + (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (59)) + (Prims.of_int (62)) (Prims.of_int (69)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (61)) - (Prims.of_int (18)) - (Prims.of_int (61)) - (Prims.of_int (102))))) + (Prims.of_int (65)) + (Prims.of_int (12)) + (Prims.of_int (65)) + (Prims.of_int (117))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (62)) + (Prims.of_int (66)) (Prims.of_int (10)) - (Prims.of_int (62)) - (Prims.of_int (34))))) + (Prims.of_int (66)) + (Prims.of_int (55))))) (Obj.magic (check1 g_extended @@ -509,6 +512,7 @@ let (check : () (FStar_Pervasives_Native.Some body_post) + binder.Pulse_Syntax_Base.binder_ppname (Pulse_Syntax_Naming.open_st_term_nv body px))) (fun @@ -519,7 +523,8 @@ let (check : g_extended body_pre body_post - r)) + r + binder.Pulse_Syntax_Base.binder_ppname)) uu___4))) (fun uu___4 -> @@ -539,11 +544,65 @@ let (check : c_body) then Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (72)) + (Prims.of_int (15)) + (Prims.of_int (73)) + (Prims.of_int (44))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (71)) + (Prims.of_int (13)) + (Prims.of_int (73)) + (Prims.of_int (44))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (73)) + (Prims.of_int (18)) + (Prims.of_int (73)) + (Prims.of_int (43))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "prims.fst" + (Prims.of_int (590)) + (Prims.of_int (19)) + (Prims.of_int (590)) + (Prims.of_int (31))))) + (Obj.magic + (Pulse_Syntax_Printer.comp_to_string + c_body)) + (fun + uu___5 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___6 -> + Prims.strcat + "check_withlocal: body computation type " + (Prims.strcat + uu___5 + " is not ST"))))) + (fun + uu___5 -> + (fun + uu___5 -> + Obj.magic (Pulse_Typing_Env.fail g1 (FStar_Pervasives_Native.Some (body.Pulse_Syntax_Base.range2)) - "withlocal: body is not stt or postcondition mismatch") + uu___5)) + uu___5)) else Obj.magic (FStar_Tactics_Effect.tac_bind @@ -551,18 +610,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (69)) + (Prims.of_int (75)) (Prims.of_int (21)) - (Prims.of_int (69)) + (Prims.of_int (75)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (70)) + (Prims.of_int (76)) (Prims.of_int (79)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -579,18 +638,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (71)) + (Prims.of_int (77)) (Prims.of_int (18)) - (Prims.of_int (71)) + (Prims.of_int (77)) (Prims.of_int (79))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (71)) + (Prims.of_int (77)) (Prims.of_int (82)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -619,35 +678,35 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (72)) + (Prims.of_int (78)) (Prims.of_int (24)) - (Prims.of_int (74)) + (Prims.of_int (80)) (Prims.of_int (100))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (75)) - (Prims.of_int (12)) (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (12)) + (Prims.of_int (87)) + (Prims.of_int (63))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (73)) + (Prims.of_int (79)) (Prims.of_int (34)) - (Prims.of_int (73)) + (Prims.of_int (79)) (Prims.of_int (59))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (74)) + (Prims.of_int (80)) (Prims.of_int (12)) - (Prims.of_int (74)) + (Prims.of_int (80)) (Prims.of_int (100))))) (FStar_Tactics_Effect.lift_div_tac (fun @@ -675,18 +734,18 @@ let (check : (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (76)) + (Prims.of_int (82)) (Prims.of_int (18)) - (Prims.of_int (80)) + (Prims.of_int (86)) (Prims.of_int (23))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Checker.WithLocal.fst" - (Prims.of_int (81)) + (Prims.of_int (87)) (Prims.of_int (10)) - (Prims.of_int (81)) - (Prims.of_int (52))))) + (Prims.of_int (87)) + (Prims.of_int (63))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___6 -> @@ -720,7 +779,8 @@ let (check : Pulse_Syntax_Base.body4 = body1 })), c, - d)))) + d)) + res_ppname)) uu___6))) uu___6))) uu___6))) @@ -734,11 +794,96 @@ let (check : uu___3))) uu___2))) uu___2)) - else - Obj.magic - (Pulse_Typing_Env.fail + else + Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (90)) + (Prims.of_int (9)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (89)) + (Prims.of_int (7)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (90)) + (Prims.of_int (9)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (90)) + (Prims.of_int (9)) + (Prims.of_int (92)) + (Prims.of_int (38))))) + (Obj.magic + (FStar_Tactics_Effect.tac_bind + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "Pulse.Checker.WithLocal.fst" + (Prims.of_int (91)) + (Prims.of_int (12)) + (Prims.of_int (91)) + (Prims.of_int (35))))) + (FStar_Sealed.seal + (Obj.magic + (FStar_Range.mk_range + "FStar.Printf.fst" + (Prims.of_int (121)) + (Prims.of_int (8)) + (Prims.of_int (123)) + (Prims.of_int (44))))) + (Obj.magic + (Pulse_Syntax_Printer.term_to_string + init1)) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + fun x -> + Prims.strcat + (Prims.strcat + "check_withlocal: allocating a local variable: type " + (Prims.strcat + uu___3 + " is not universe zero (computed ")) + (Prims.strcat + x ")"))))) + (fun + uu___3 -> + FStar_Tactics_Effect.lift_div_tac + (fun + uu___4 -> + uu___3 + (Pulse_Syntax_Printer.univ_to_string + init_u))))) + (fun + uu___3 -> + (fun + uu___3 -> + Obj.magic + (Pulse_Typing_Env.fail g1 - FStar_Pervasives_Native.None - "Allocating a local variable: init type is not universe zero")) - uu___1))) uu___))) - uu___))) uu___) \ No newline at end of file + (FStar_Pervasives_Native.Some + (t.Pulse_Syntax_Base.range2)) + uu___3)) + uu___3))) + uu___1))) uu___))) + uu___))) uu___) \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Syntax_Base.ml b/src/ocaml/plugin/generated/Pulse_Syntax_Base.ml index aa551e02f..ba293735d 100644 --- a/src/ocaml/plugin/generated/Pulse_Syntax_Base.ml +++ b/src/ocaml/plugin/generated/Pulse_Syntax_Base.ml @@ -18,6 +18,8 @@ let (ppname_default : ppname) = let (mk_ppname : FStar_Reflection_Typing.pp_name_t -> FStar_Range.range -> ppname) = fun name -> fun range1 -> { name; range = range1 } +let (mk_ppname_no_range : Prims.string -> ppname) = + fun s -> { name = (FStar_Sealed.seal s); range = FStar_Range.range_0 } type bv = { bv_index: index ; bv_ppname: ppname } diff --git a/src/ocaml/plugin/generated/Pulse_Syntax_Printer.ml b/src/ocaml/plugin/generated/Pulse_Syntax_Printer.ml index 3f0b8c828..9d0d220be 100644 --- a/src/ocaml/plugin/generated/Pulse_Syntax_Printer.ml +++ b/src/ocaml/plugin/generated/Pulse_Syntax_Printer.ml @@ -553,6 +553,12 @@ let (binder_to_string : (fun uu___1 -> FStar_Tactics_Effect.lift_div_tac (fun uu___2 -> uu___1 uu___)))) uu___) +let (ctag_to_string : Pulse_Syntax_Base.ctag -> Prims.string) = + fun uu___ -> + match uu___ with + | Pulse_Syntax_Base.STT -> "ST" + | Pulse_Syntax_Base.STT_Atomic -> "STAtomic" + | Pulse_Syntax_Base.STT_Ghost -> "STGhost" let (comp_to_string : Pulse_Syntax_Base.comp -> (Prims.string, unit) FStar_Tactics_Effect.tac_repr) @@ -564,8 +570,8 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (89)) (Prims.of_int (23)) - (Prims.of_int (89)) (Prims.of_int (41))))) + (Prims.of_int (94)) (Prims.of_int (23)) + (Prims.of_int (94)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" (Prims.of_int (590)) @@ -579,13 +585,13 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (95)) (Prims.of_int (14)) - (Prims.of_int (95)) (Prims.of_int (37))))) + (Prims.of_int (100)) (Prims.of_int (14)) + (Prims.of_int (100)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) (Prims.of_int (6)) (Prims.of_int (95)) - (Prims.of_int (37))))) + (Prims.of_int (97)) (Prims.of_int (6)) + (Prims.of_int (100)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.post)) (fun uu___ -> (fun uu___ -> @@ -594,27 +600,27 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) (Prims.of_int (6)) - (Prims.of_int (95)) (Prims.of_int (37))))) + (Prims.of_int (97)) (Prims.of_int (6)) + (Prims.of_int (100)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) (Prims.of_int (6)) - (Prims.of_int (95)) (Prims.of_int (37))))) + (Prims.of_int (97)) (Prims.of_int (6)) + (Prims.of_int (100)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (94)) (Prims.of_int (14)) - (Prims.of_int (94)) (Prims.of_int (36))))) + (Prims.of_int (99)) (Prims.of_int (14)) + (Prims.of_int (99)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) (Prims.of_int (6)) - (Prims.of_int (95)) (Prims.of_int (37))))) + (Prims.of_int (97)) (Prims.of_int (6)) + (Prims.of_int (100)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.pre)) (fun uu___1 -> @@ -625,17 +631,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) + (Prims.of_int (97)) (Prims.of_int (6)) - (Prims.of_int (95)) + (Prims.of_int (100)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (92)) + (Prims.of_int (97)) (Prims.of_int (6)) - (Prims.of_int (95)) + (Prims.of_int (100)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -643,9 +649,9 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (93)) + (Prims.of_int (98)) (Prims.of_int (14)) - (Prims.of_int (93)) + (Prims.of_int (98)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic @@ -686,13 +692,13 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (102)) (Prims.of_int (14)) - (Prims.of_int (102)) (Prims.of_int (37))))) + (Prims.of_int (107)) (Prims.of_int (14)) + (Prims.of_int (107)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) (Prims.of_int (6)) - (Prims.of_int (102)) (Prims.of_int (37))))) + (Prims.of_int (103)) (Prims.of_int (6)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.post)) (fun uu___ -> (fun uu___ -> @@ -701,27 +707,27 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) (Prims.of_int (6)) - (Prims.of_int (102)) (Prims.of_int (37))))) + (Prims.of_int (103)) (Prims.of_int (6)) + (Prims.of_int (107)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) (Prims.of_int (6)) - (Prims.of_int (102)) (Prims.of_int (37))))) + (Prims.of_int (103)) (Prims.of_int (6)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (101)) (Prims.of_int (14)) - (Prims.of_int (101)) (Prims.of_int (36))))) + (Prims.of_int (106)) (Prims.of_int (14)) + (Prims.of_int (106)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) (Prims.of_int (6)) - (Prims.of_int (102)) (Prims.of_int (37))))) + (Prims.of_int (103)) (Prims.of_int (6)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.pre)) (fun uu___1 -> @@ -732,17 +738,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) + (Prims.of_int (103)) (Prims.of_int (6)) - (Prims.of_int (102)) + (Prims.of_int (107)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) + (Prims.of_int (103)) (Prims.of_int (6)) - (Prims.of_int (102)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -750,17 +756,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (100)) + (Prims.of_int (105)) (Prims.of_int (14)) - (Prims.of_int (100)) + (Prims.of_int (105)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) + (Prims.of_int (103)) (Prims.of_int (6)) - (Prims.of_int (102)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (term_to_string @@ -773,17 +779,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) + (Prims.of_int (103)) (Prims.of_int (6)) - (Prims.of_int (102)) + (Prims.of_int (107)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (98)) + (Prims.of_int (103)) (Prims.of_int (6)) - (Prims.of_int (102)) + (Prims.of_int (107)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -791,9 +797,9 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (99)) + (Prims.of_int (104)) (Prims.of_int (14)) - (Prims.of_int (99)) + (Prims.of_int (104)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic @@ -846,13 +852,13 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (109)) (Prims.of_int (14)) - (Prims.of_int (109)) (Prims.of_int (37))))) + (Prims.of_int (114)) (Prims.of_int (14)) + (Prims.of_int (114)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) (Prims.of_int (6)) - (Prims.of_int (109)) (Prims.of_int (37))))) + (Prims.of_int (110)) (Prims.of_int (6)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.post)) (fun uu___ -> (fun uu___ -> @@ -861,27 +867,27 @@ let (comp_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) (Prims.of_int (6)) - (Prims.of_int (109)) (Prims.of_int (37))))) + (Prims.of_int (110)) (Prims.of_int (6)) + (Prims.of_int (114)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) (Prims.of_int (6)) - (Prims.of_int (109)) (Prims.of_int (37))))) + (Prims.of_int (110)) (Prims.of_int (6)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (108)) (Prims.of_int (14)) - (Prims.of_int (108)) (Prims.of_int (36))))) + (Prims.of_int (113)) (Prims.of_int (14)) + (Prims.of_int (113)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) (Prims.of_int (6)) - (Prims.of_int (109)) (Prims.of_int (37))))) + (Prims.of_int (110)) (Prims.of_int (6)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (term_to_string s.Pulse_Syntax_Base.pre)) (fun uu___1 -> @@ -892,17 +898,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) + (Prims.of_int (110)) (Prims.of_int (6)) - (Prims.of_int (109)) + (Prims.of_int (114)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) + (Prims.of_int (110)) (Prims.of_int (6)) - (Prims.of_int (109)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -910,17 +916,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (107)) + (Prims.of_int (112)) (Prims.of_int (14)) - (Prims.of_int (107)) + (Prims.of_int (112)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) + (Prims.of_int (110)) (Prims.of_int (6)) - (Prims.of_int (109)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (term_to_string @@ -933,17 +939,17 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) + (Prims.of_int (110)) (Prims.of_int (6)) - (Prims.of_int (109)) + (Prims.of_int (114)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (105)) + (Prims.of_int (110)) (Prims.of_int (6)) - (Prims.of_int (109)) + (Prims.of_int (114)) (Prims.of_int (37))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -951,9 +957,9 @@ let (comp_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (106)) + (Prims.of_int (111)) (Prims.of_int (14)) - (Prims.of_int (106)) + (Prims.of_int (111)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic @@ -1024,12 +1030,12 @@ let (term_list_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (119)) (Prims.of_int (22)) - (Prims.of_int (119)) (Prims.of_int (46))))) + (Prims.of_int (124)) (Prims.of_int (22)) + (Prims.of_int (124)) (Prims.of_int (46))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (119)) (Prims.of_int (4)) (Prims.of_int (119)) + (Prims.of_int (124)) (Prims.of_int (4)) (Prims.of_int (124)) (Prims.of_int (46))))) (Obj.magic (FStar_Tactics_Util.map term_to_string t)) (fun uu___ -> @@ -1052,8 +1058,8 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (131)) (Prims.of_int (8)) - (Prims.of_int (131)) (Prims.of_int (29))))) + (Prims.of_int (136)) (Prims.of_int (8)) + (Prims.of_int (136)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" (Prims.of_int (590)) @@ -1083,13 +1089,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (138)) (Prims.of_int (8)) - (Prims.of_int (138)) (Prims.of_int (28))))) + (Prims.of_int (143)) (Prims.of_int (8)) + (Prims.of_int (143)) (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (138)) (Prims.of_int (28))))) + (Prims.of_int (139)) (Prims.of_int (6)) + (Prims.of_int (143)) (Prims.of_int (28))))) (Obj.magic (term_to_string arg)) (fun uu___ -> (fun uu___ -> @@ -1098,28 +1104,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (138)) (Prims.of_int (28))))) + (Prims.of_int (139)) (Prims.of_int (6)) + (Prims.of_int (143)) (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (138)) (Prims.of_int (28))))) + (Prims.of_int (139)) (Prims.of_int (6)) + (Prims.of_int (143)) (Prims.of_int (28))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (6)) + (Prims.of_int (143)) (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (134)) (Prims.of_int (6)) - (Prims.of_int (138)) + (Prims.of_int (139)) (Prims.of_int (6)) + (Prims.of_int (143)) (Prims.of_int (28))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1127,9 +1133,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (136)) + (Prims.of_int (141)) (Prims.of_int (8)) - (Prims.of_int (136)) + (Prims.of_int (141)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic @@ -1172,13 +1178,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (151)) (Prims.of_int (10)) - (Prims.of_int (151)) (Prims.of_int (41))))) + (Prims.of_int (156)) (Prims.of_int (10)) + (Prims.of_int (156)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (151)) (Prims.of_int (41))))) + (Prims.of_int (152)) (Prims.of_int (8)) + (Prims.of_int (156)) (Prims.of_int (41))))) (Obj.magic (st_term_to_string' level body)) (fun uu___ -> (fun uu___ -> @@ -1187,28 +1193,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (151)) (Prims.of_int (41))))) + (Prims.of_int (152)) (Prims.of_int (8)) + (Prims.of_int (156)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (151)) (Prims.of_int (41))))) + (Prims.of_int (152)) (Prims.of_int (8)) + (Prims.of_int (156)) (Prims.of_int (41))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (151)) + (Prims.of_int (152)) (Prims.of_int (8)) + (Prims.of_int (156)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) (Prims.of_int (8)) - (Prims.of_int (151)) + (Prims.of_int (152)) (Prims.of_int (8)) + (Prims.of_int (156)) (Prims.of_int (41))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1216,17 +1222,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (149)) + (Prims.of_int (154)) (Prims.of_int (10)) - (Prims.of_int (149)) + (Prims.of_int (154)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) + (Prims.of_int (152)) (Prims.of_int (8)) - (Prims.of_int (151)) + (Prims.of_int (156)) (Prims.of_int (41))))) (Obj.magic (st_term_to_string' level head)) (fun uu___1 -> @@ -1237,17 +1243,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) + (Prims.of_int (152)) (Prims.of_int (8)) - (Prims.of_int (151)) + (Prims.of_int (156)) (Prims.of_int (41))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (147)) + (Prims.of_int (152)) (Prims.of_int (8)) - (Prims.of_int (151)) + (Prims.of_int (156)) (Prims.of_int (41))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1255,9 +1261,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (148)) + (Prims.of_int (153)) (Prims.of_int (10)) - (Prims.of_int (148)) + (Prims.of_int (153)) (Prims.of_int (35))))) (FStar_Sealed.seal (Obj.magic @@ -1310,13 +1316,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (158)) (Prims.of_int (8)) - (Prims.of_int (158)) (Prims.of_int (39))))) + (Prims.of_int (163)) (Prims.of_int (8)) + (Prims.of_int (163)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (155)) (Prims.of_int (6)) - (Prims.of_int (158)) (Prims.of_int (39))))) + (Prims.of_int (160)) (Prims.of_int (6)) + (Prims.of_int (163)) (Prims.of_int (39))))) (Obj.magic (st_term_to_string' level body)) (fun uu___ -> (fun uu___ -> @@ -1325,28 +1331,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (155)) (Prims.of_int (6)) - (Prims.of_int (158)) (Prims.of_int (39))))) + (Prims.of_int (160)) (Prims.of_int (6)) + (Prims.of_int (163)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (155)) (Prims.of_int (6)) - (Prims.of_int (158)) (Prims.of_int (39))))) + (Prims.of_int (160)) (Prims.of_int (6)) + (Prims.of_int (163)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (155)) (Prims.of_int (6)) - (Prims.of_int (158)) + (Prims.of_int (160)) (Prims.of_int (6)) + (Prims.of_int (163)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (155)) (Prims.of_int (6)) - (Prims.of_int (158)) + (Prims.of_int (160)) (Prims.of_int (6)) + (Prims.of_int (163)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1354,9 +1360,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (156)) + (Prims.of_int (161)) (Prims.of_int (8)) - (Prims.of_int (156)) + (Prims.of_int (161)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic @@ -1395,13 +1401,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (166)) (Prims.of_int (14)) - (Prims.of_int (166)) (Prims.of_int (54))))) + (Prims.of_int (171)) (Prims.of_int (14)) + (Prims.of_int (171)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) (Prims.of_int (6)) - (Prims.of_int (166)) (Prims.of_int (54))))) + (Prims.of_int (166)) (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (Obj.magic (st_term_to_string' (indent level) body)) (fun uu___ -> (fun uu___ -> @@ -1410,28 +1416,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) (Prims.of_int (6)) - (Prims.of_int (166)) (Prims.of_int (54))))) + (Prims.of_int (166)) (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) (Prims.of_int (6)) - (Prims.of_int (166)) (Prims.of_int (54))))) + (Prims.of_int (166)) (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) (Prims.of_int (6)) - (Prims.of_int (166)) + (Prims.of_int (166)) (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) (Prims.of_int (6)) - (Prims.of_int (166)) + (Prims.of_int (166)) (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1439,17 +1445,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (164)) + (Prims.of_int (169)) (Prims.of_int (14)) - (Prims.of_int (164)) + (Prims.of_int (169)) (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) - (Prims.of_int (6)) (Prims.of_int (166)) + (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (Obj.magic (comp_to_string c)) (fun uu___1 -> @@ -1460,17 +1466,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) - (Prims.of_int (6)) (Prims.of_int (166)) + (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (161)) - (Prims.of_int (6)) (Prims.of_int (166)) + (Prims.of_int (6)) + (Prims.of_int (171)) (Prims.of_int (54))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1478,9 +1484,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (163)) + (Prims.of_int (168)) (Prims.of_int (14)) - (Prims.of_int (163)) + (Prims.of_int (168)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic @@ -1539,25 +1545,25 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) (Prims.of_int (6)) - (Prims.of_int (179)) (Prims.of_int (13))))) + (Prims.of_int (174)) (Prims.of_int (6)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) (Prims.of_int (6)) - (Prims.of_int (179)) (Prims.of_int (13))))) + (Prims.of_int (174)) (Prims.of_int (6)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (178)) (Prims.of_int (8)) - (Prims.of_int (178)) (Prims.of_int (49))))) + (Prims.of_int (183)) (Prims.of_int (8)) + (Prims.of_int (183)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) (Prims.of_int (6)) - (Prims.of_int (179)) (Prims.of_int (13))))) + (Prims.of_int (174)) (Prims.of_int (6)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (st_term_to_string' (indent level) else_)) (fun uu___1 -> (fun uu___1 -> @@ -1567,15 +1573,15 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (174)) (Prims.of_int (6)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (174)) (Prims.of_int (6)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1583,17 +1589,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1601,17 +1607,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1619,17 +1625,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1637,17 +1643,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1655,17 +1661,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (173)) + (Prims.of_int (178)) (Prims.of_int (8)) - (Prims.of_int (173)) + (Prims.of_int (178)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (st_term_to_string' @@ -1680,17 +1686,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1698,17 +1704,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1716,17 +1722,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (169)) + (Prims.of_int (174)) (Prims.of_int (6)) - (Prims.of_int (179)) + (Prims.of_int (184)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1734,9 +1740,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (170)) + (Prims.of_int (175)) (Prims.of_int (8)) - (Prims.of_int (170)) + (Prims.of_int (175)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic @@ -1846,13 +1852,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (184)) (Prims.of_int (8)) - (Prims.of_int (184)) (Prims.of_int (32))))) + (Prims.of_int (189)) (Prims.of_int (8)) + (Prims.of_int (189)) (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (182)) (Prims.of_int (6)) - (Prims.of_int (184)) (Prims.of_int (32))))) + (Prims.of_int (187)) (Prims.of_int (6)) + (Prims.of_int (189)) (Prims.of_int (32))))) (Obj.magic (branches_to_string brs)) (fun uu___1 -> (fun uu___1 -> @@ -1861,21 +1867,21 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (182)) (Prims.of_int (6)) - (Prims.of_int (184)) (Prims.of_int (32))))) + (Prims.of_int (187)) (Prims.of_int (6)) + (Prims.of_int (189)) (Prims.of_int (32))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (182)) (Prims.of_int (6)) - (Prims.of_int (184)) (Prims.of_int (32))))) + (Prims.of_int (187)) (Prims.of_int (6)) + (Prims.of_int (189)) (Prims.of_int (32))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (183)) (Prims.of_int (8)) - (Prims.of_int (183)) + (Prims.of_int (188)) (Prims.of_int (8)) + (Prims.of_int (188)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic @@ -1900,8 +1906,8 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (189)) (Prims.of_int (8)) - (Prims.of_int (189)) (Prims.of_int (42))))) + (Prims.of_int (194)) (Prims.of_int (8)) + (Prims.of_int (194)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" (Prims.of_int (590)) @@ -1920,8 +1926,8 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (193)) (Prims.of_int (8)) - (Prims.of_int (193)) (Prims.of_int (26))))) + (Prims.of_int (198)) (Prims.of_int (8)) + (Prims.of_int (198)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" (Prims.of_int (590)) @@ -1939,13 +1945,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (200)) (Prims.of_int (8)) - (Prims.of_int (200)) (Prims.of_int (43))))) + (Prims.of_int (205)) (Prims.of_int (8)) + (Prims.of_int (205)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (196)) (Prims.of_int (6)) - (Prims.of_int (200)) (Prims.of_int (43))))) + (Prims.of_int (201)) (Prims.of_int (6)) + (Prims.of_int (205)) (Prims.of_int (43))))) (Obj.magic (term_list_to_string " " witnesses)) (fun uu___ -> (fun uu___ -> @@ -1954,28 +1960,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (196)) (Prims.of_int (6)) - (Prims.of_int (200)) (Prims.of_int (43))))) + (Prims.of_int (201)) (Prims.of_int (6)) + (Prims.of_int (205)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (196)) (Prims.of_int (6)) - (Prims.of_int (200)) (Prims.of_int (43))))) + (Prims.of_int (201)) (Prims.of_int (6)) + (Prims.of_int (205)) (Prims.of_int (43))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (196)) (Prims.of_int (6)) - (Prims.of_int (200)) + (Prims.of_int (201)) (Prims.of_int (6)) + (Prims.of_int (205)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (196)) (Prims.of_int (6)) - (Prims.of_int (200)) + (Prims.of_int (201)) (Prims.of_int (6)) + (Prims.of_int (205)) (Prims.of_int (43))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -1983,9 +1989,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (198)) + (Prims.of_int (203)) (Prims.of_int (8)) - (Prims.of_int (198)) + (Prims.of_int (203)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic @@ -2028,13 +2034,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (207)) (Prims.of_int (8)) - (Prims.of_int (207)) (Prims.of_int (43))))) + (Prims.of_int (212)) (Prims.of_int (8)) + (Prims.of_int (212)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (203)) (Prims.of_int (6)) - (Prims.of_int (207)) (Prims.of_int (43))))) + (Prims.of_int (208)) (Prims.of_int (6)) + (Prims.of_int (212)) (Prims.of_int (43))))) (Obj.magic (term_list_to_string " " witnesses)) (fun uu___ -> (fun uu___ -> @@ -2043,28 +2049,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (203)) (Prims.of_int (6)) - (Prims.of_int (207)) (Prims.of_int (43))))) + (Prims.of_int (208)) (Prims.of_int (6)) + (Prims.of_int (212)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (203)) (Prims.of_int (6)) - (Prims.of_int (207)) (Prims.of_int (43))))) + (Prims.of_int (208)) (Prims.of_int (6)) + (Prims.of_int (212)) (Prims.of_int (43))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (203)) (Prims.of_int (6)) - (Prims.of_int (207)) + (Prims.of_int (208)) (Prims.of_int (6)) + (Prims.of_int (212)) (Prims.of_int (43))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (203)) (Prims.of_int (6)) - (Prims.of_int (207)) + (Prims.of_int (208)) (Prims.of_int (6)) + (Prims.of_int (212)) (Prims.of_int (43))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2072,9 +2078,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (205)) + (Prims.of_int (210)) (Prims.of_int (8)) - (Prims.of_int (205)) + (Prims.of_int (210)) (Prims.of_int (42))))) (FStar_Sealed.seal (Obj.magic @@ -2119,25 +2125,25 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) (Prims.of_int (6)) - (Prims.of_int (217)) (Prims.of_int (13))))) + (Prims.of_int (215)) (Prims.of_int (6)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) (Prims.of_int (6)) - (Prims.of_int (217)) (Prims.of_int (13))))) + (Prims.of_int (215)) (Prims.of_int (6)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (216)) (Prims.of_int (8)) - (Prims.of_int (216)) (Prims.of_int (48))))) + (Prims.of_int (221)) (Prims.of_int (8)) + (Prims.of_int (221)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) (Prims.of_int (6)) - (Prims.of_int (217)) (Prims.of_int (13))))) + (Prims.of_int (215)) (Prims.of_int (6)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (st_term_to_string' (indent level) body)) (fun uu___1 -> (fun uu___1 -> @@ -2147,15 +2153,15 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (215)) (Prims.of_int (6)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (215)) (Prims.of_int (6)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2163,17 +2169,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2181,17 +2187,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2199,17 +2205,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (213)) + (Prims.of_int (218)) (Prims.of_int (8)) - (Prims.of_int (213)) + (Prims.of_int (218)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (term_to_string invariant)) @@ -2221,17 +2227,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2239,17 +2245,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (210)) + (Prims.of_int (215)) (Prims.of_int (6)) - (Prims.of_int (217)) + (Prims.of_int (222)) (Prims.of_int (13))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2257,9 +2263,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (211)) + (Prims.of_int (216)) (Prims.of_int (8)) - (Prims.of_int (211)) + (Prims.of_int (216)) (Prims.of_int (44))))) (FStar_Sealed.seal (Obj.magic @@ -2342,13 +2348,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (226)) (Prims.of_int (8)) - (Prims.of_int (226)) (Prims.of_int (30))))) + (Prims.of_int (231)) (Prims.of_int (8)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) (Prims.of_int (6)) - (Prims.of_int (226)) (Prims.of_int (30))))) + (Prims.of_int (225)) (Prims.of_int (6)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (term_to_string post2)) (fun uu___ -> (fun uu___ -> @@ -2357,28 +2363,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) (Prims.of_int (6)) - (Prims.of_int (226)) (Prims.of_int (30))))) + (Prims.of_int (225)) (Prims.of_int (6)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) (Prims.of_int (6)) - (Prims.of_int (226)) (Prims.of_int (30))))) + (Prims.of_int (225)) (Prims.of_int (6)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (225)) (Prims.of_int (8)) - (Prims.of_int (225)) + (Prims.of_int (230)) (Prims.of_int (8)) + (Prims.of_int (230)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (225)) (Prims.of_int (6)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (st_term_to_string' level body2)) (fun uu___1 -> @@ -2389,17 +2395,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2407,17 +2413,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (224)) + (Prims.of_int (229)) (Prims.of_int (8)) - (Prims.of_int (224)) + (Prims.of_int (229)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (term_to_string pre2)) @@ -2429,17 +2435,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2447,17 +2453,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (223)) + (Prims.of_int (228)) (Prims.of_int (8)) - (Prims.of_int (223)) + (Prims.of_int (228)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (term_to_string @@ -2471,17 +2477,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2489,17 +2495,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (222)) + (Prims.of_int (227)) (Prims.of_int (8)) - (Prims.of_int (222)) + (Prims.of_int (227)) (Prims.of_int (40))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (st_term_to_string' @@ -2515,17 +2521,17 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (220)) + (Prims.of_int (225)) (Prims.of_int (6)) - (Prims.of_int (226)) + (Prims.of_int (231)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2533,9 +2539,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (221)) + (Prims.of_int (226)) (Prims.of_int (8)) - (Prims.of_int (221)) + (Prims.of_int (226)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic @@ -2613,13 +2619,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (231)) (Prims.of_int (15)) - (Prims.of_int (231)) (Prims.of_int (34))))) + (Prims.of_int (236)) (Prims.of_int (15)) + (Prims.of_int (236)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (229)) (Prims.of_int (7)) - (Prims.of_int (231)) (Prims.of_int (34))))) + (Prims.of_int (234)) (Prims.of_int (7)) + (Prims.of_int (236)) (Prims.of_int (34))))) (Obj.magic (term_to_string t2)) (fun uu___ -> (fun uu___ -> @@ -2628,21 +2634,21 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (229)) (Prims.of_int (7)) - (Prims.of_int (231)) (Prims.of_int (34))))) + (Prims.of_int (234)) (Prims.of_int (7)) + (Prims.of_int (236)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (229)) (Prims.of_int (7)) - (Prims.of_int (231)) (Prims.of_int (34))))) + (Prims.of_int (234)) (Prims.of_int (7)) + (Prims.of_int (236)) (Prims.of_int (34))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (230)) (Prims.of_int (8)) - (Prims.of_int (230)) + (Prims.of_int (235)) (Prims.of_int (8)) + (Prims.of_int (235)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic @@ -2671,13 +2677,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (237)) (Prims.of_int (8)) - (Prims.of_int (237)) (Prims.of_int (39))))) + (Prims.of_int (242)) (Prims.of_int (8)) + (Prims.of_int (242)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (234)) (Prims.of_int (6)) - (Prims.of_int (237)) (Prims.of_int (39))))) + (Prims.of_int (239)) (Prims.of_int (6)) + (Prims.of_int (242)) (Prims.of_int (39))))) (Obj.magic (st_term_to_string' level body)) (fun uu___1 -> (fun uu___1 -> @@ -2686,28 +2692,28 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (234)) (Prims.of_int (6)) - (Prims.of_int (237)) (Prims.of_int (39))))) + (Prims.of_int (239)) (Prims.of_int (6)) + (Prims.of_int (242)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (234)) (Prims.of_int (6)) - (Prims.of_int (237)) (Prims.of_int (39))))) + (Prims.of_int (239)) (Prims.of_int (6)) + (Prims.of_int (242)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (234)) (Prims.of_int (6)) - (Prims.of_int (237)) + (Prims.of_int (239)) (Prims.of_int (6)) + (Prims.of_int (242)) (Prims.of_int (39))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (234)) (Prims.of_int (6)) - (Prims.of_int (237)) + (Prims.of_int (239)) (Prims.of_int (6)) + (Prims.of_int (242)) (Prims.of_int (39))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -2715,9 +2721,9 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (235)) + (Prims.of_int (240)) (Prims.of_int (8)) - (Prims.of_int (235)) + (Prims.of_int (240)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic @@ -2755,13 +2761,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (247)) (Prims.of_int (8)) - (Prims.of_int (249)) (Prims.of_int (60))))) + (Prims.of_int (252)) (Prims.of_int (8)) + (Prims.of_int (254)) (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (240)) (Prims.of_int (6)) - (Prims.of_int (249)) (Prims.of_int (60))))) + (Prims.of_int (245)) (Prims.of_int (6)) + (Prims.of_int (254)) (Prims.of_int (60))))) (match post with | FStar_Pervasives_Native.None -> Obj.magic @@ -2775,8 +2781,8 @@ let rec (st_term_to_string' : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (249)) (Prims.of_int (38)) - (Prims.of_int (249)) (Prims.of_int (59))))) + (Prims.of_int (254)) (Prims.of_int (38)) + (Prims.of_int (254)) (Prims.of_int (59))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" @@ -2794,21 +2800,21 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (240)) (Prims.of_int (6)) - (Prims.of_int (249)) (Prims.of_int (60))))) + (Prims.of_int (245)) (Prims.of_int (6)) + (Prims.of_int (254)) (Prims.of_int (60))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (240)) (Prims.of_int (6)) - (Prims.of_int (249)) (Prims.of_int (60))))) + (Prims.of_int (245)) (Prims.of_int (6)) + (Prims.of_int (254)) (Prims.of_int (60))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (246)) (Prims.of_int (8)) - (Prims.of_int (246)) + (Prims.of_int (251)) (Prims.of_int (8)) + (Prims.of_int (251)) (Prims.of_int (28))))) (FStar_Sealed.seal (Obj.magic @@ -2853,13 +2859,13 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (257)) (Prims.of_int (8)) - (Prims.of_int (257)) (Prims.of_int (36))))) + (Prims.of_int (262)) (Prims.of_int (8)) + (Prims.of_int (262)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (252)) (Prims.of_int (6)) - (Prims.of_int (257)) (Prims.of_int (36))))) + (Prims.of_int (257)) (Prims.of_int (6)) + (Prims.of_int (262)) (Prims.of_int (36))))) (Obj.magic (st_term_to_string' level t1)) (fun uu___1 -> (fun uu___1 -> @@ -2868,21 +2874,21 @@ let rec (st_term_to_string' : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (252)) (Prims.of_int (6)) - (Prims.of_int (257)) (Prims.of_int (36))))) + (Prims.of_int (257)) (Prims.of_int (6)) + (Prims.of_int (262)) (Prims.of_int (36))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (252)) (Prims.of_int (6)) - (Prims.of_int (257)) (Prims.of_int (36))))) + (Prims.of_int (257)) (Prims.of_int (6)) + (Prims.of_int (262)) (Prims.of_int (36))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (256)) (Prims.of_int (8)) - (Prims.of_int (256)) + (Prims.of_int (261)) (Prims.of_int (8)) + (Prims.of_int (261)) (Prims.of_int (26))))) (FStar_Sealed.seal (Obj.magic @@ -2939,13 +2945,13 @@ and (branches_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (262)) (Prims.of_int (13)) - (Prims.of_int (262)) (Prims.of_int (31))))) + (Prims.of_int (267)) (Prims.of_int (13)) + (Prims.of_int (267)) (Prims.of_int (31))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (262)) (Prims.of_int (13)) - (Prims.of_int (262)) (Prims.of_int (55))))) + (Prims.of_int (267)) (Prims.of_int (13)) + (Prims.of_int (267)) (Prims.of_int (55))))) (Obj.magic (branch_to_string b)) (fun uu___ -> (fun uu___ -> @@ -2955,9 +2961,9 @@ and (branches_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (262)) + (Prims.of_int (267)) (Prims.of_int (34)) - (Prims.of_int (262)) + (Prims.of_int (267)) (Prims.of_int (55))))) (FStar_Sealed.seal (Obj.magic @@ -2980,12 +2986,12 @@ and (branch_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (265)) (Prims.of_int (17)) (Prims.of_int (265)) + (Prims.of_int (270)) (Prims.of_int (17)) (Prims.of_int (270)) (Prims.of_int (19))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (264)) (Prims.of_int (35)) (Prims.of_int (266)) + (Prims.of_int (269)) (Prims.of_int (35)) (Prims.of_int (271)) (Prims.of_int (25))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> br)) (fun uu___ -> @@ -3051,8 +3057,8 @@ let (tag_of_comp : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (307)) (Prims.of_int (31)) - (Prims.of_int (307)) (Prims.of_int (49))))) + (Prims.of_int (312)) (Prims.of_int (31)) + (Prims.of_int (312)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" @@ -3070,8 +3076,8 @@ let (tag_of_comp : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Syntax.Printer.fst" - (Prims.of_int (309)) (Prims.of_int (30)) - (Prims.of_int (309)) (Prims.of_int (48))))) + (Prims.of_int (314)) (Prims.of_int (30)) + (Prims.of_int (314)) (Prims.of_int (48))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" diff --git a/src/ocaml/plugin/generated/Pulse_Typing_Combinators.ml b/src/ocaml/plugin/generated/Pulse_Typing_Combinators.ml index 38003210f..ab68e13d0 100644 --- a/src/ocaml/plugin/generated/Pulse_Typing_Combinators.ml +++ b/src/ocaml/plugin/generated/Pulse_Typing_Combinators.ml @@ -1160,7 +1160,7 @@ let (apply_frame : Pulse_Typing.T_Frame (g, t, c, frame, (), t_typing) in let c' = Pulse_Typing.add_frame c frame in let c'_typing = - Pulse_Typing_Metatheory.st_typing_correctness g t + Pulse_Typing_Metatheory_Base.st_typing_correctness g t (Pulse_Typing.add_frame c frame) t_typing1 in let s' = Pulse_Syntax_Base.st_comp_of_comp c' in let s'' = @@ -1172,10 +1172,10 @@ let (apply_frame : } in let c'' = Pulse_Syntax_Base.with_st_comp c' s'' in let st_typing = - Pulse_Typing_Metatheory.comp_typing_inversion g + Pulse_Typing_Metatheory_Base.comp_typing_inversion g (Pulse_Typing.add_frame c frame) c'_typing in let uu___1 = - Pulse_Typing_Metatheory.st_comp_typing_inversion g + Pulse_Typing_Metatheory_Base.st_comp_typing_inversion g (Pulse_Syntax_Base.st_comp_of_comp (Pulse_Typing.add_frame c frame)) st_typing in (match uu___1 with @@ -1190,7 +1190,7 @@ let (apply_frame : t_typing1, st_equiv) in Prims.Mkdtuple2 (c'', t_typing2)) type ('g, 'ctxt, 'postuhint) st_typing_in_ctxt = - (Pulse_Syntax_Base.st_term, Pulse_Syntax_Base.comp, + (Pulse_Syntax_Base.st_term, Pulse_Syntax_Base.comp_st, (unit, unit, unit) Pulse_Typing.st_typing) FStar_Pervasives.dtuple3 let rec (vprop_as_list : Pulse_Syntax_Base.term -> Pulse_Syntax_Base.term Prims.list) = diff --git a/src/ocaml/plugin/generated/Pulse_Typing_Env.ml b/src/ocaml/plugin/generated/Pulse_Typing_Env.ml index ff50a2fe0..a417111e9 100644 --- a/src/ocaml/plugin/generated/Pulse_Typing_Env.ml +++ b/src/ocaml/plugin/generated/Pulse_Typing_Env.ml @@ -52,6 +52,13 @@ let (push_binding : m = (FStar_Map.upd g.m x t); ctxt = (g.ctxt) } +let (singleton_env : + FStar_Reflection_Typing.fstar_top_env -> + Pulse_Syntax_Base.var -> Pulse_Syntax_Base.typ -> env) + = + fun f -> + fun x -> + fun t -> push_binding (mk_env f) x Pulse_Syntax_Base.ppname_default t let (push_binding_def : env -> Pulse_Syntax_Base.var -> Pulse_Syntax_Base.typ -> env) = fun g -> @@ -86,6 +93,7 @@ let (fresh : env -> Pulse_Syntax_Base.var) = let (contains : env -> Pulse_Syntax_Base.var -> Prims.bool) = fun g -> fun x -> FStar_Map.contains (as_map g) x type ('g1, 'g2) disjoint = unit +type ('g, 'gu, 'guu) pairwise_disjoint = unit let (push_env : env -> env -> env) = fun g1 -> fun g2 -> @@ -196,6 +204,18 @@ let (diff : env -> env -> env) = let g31 = { f = (g1.f); bs = bs3; names = names3; m = m3; ctxt = (g1.ctxt) } in g31 +let rec (subst_env : env -> Pulse_Syntax_Naming.subst -> env) = + fun en -> + fun ss -> + match bindings en with + | [] -> en + | uu___ -> + let uu___1 = remove_latest_binding en in + (match uu___1 with + | (x, t, en1) -> + push_binding (subst_env en1 ss) x + Pulse_Syntax_Base.ppname_default + (Pulse_Syntax_Naming.subst_term t ss)) let (push_context : env -> Prims.string -> Pulse_Syntax_Base.range -> env) = fun g -> fun ctx -> @@ -228,12 +248,12 @@ let (range_of_env : FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (271)) - (Prims.of_int (14)) (Prims.of_int (271)) (Prims.of_int (29))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (282)) + (Prims.of_int (14)) (Prims.of_int (282)) (Prims.of_int (29))))) (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (272)) - (Prims.of_int (4)) (Prims.of_int (280)) (Prims.of_int (30))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (283)) + (Prims.of_int (4)) (Prims.of_int (291)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Unseal.unseal g.ctxt)) (fun uu___ -> (fun ctx -> @@ -242,13 +262,13 @@ let (range_of_env : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (273)) (Prims.of_int (6)) - (Prims.of_int (278)) (Prims.of_int (66))))) + (Prims.of_int (284)) (Prims.of_int (6)) + (Prims.of_int (289)) (Prims.of_int (66))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (272)) (Prims.of_int (4)) - (Prims.of_int (280)) (Prims.of_int (30))))) + (Prims.of_int (283)) (Prims.of_int (4)) + (Prims.of_int (291)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Util.tryPick (fun uu___ -> @@ -298,8 +318,8 @@ let (ctxt_elt_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (287)) (Prims.of_int (49)) - (Prims.of_int (287)) (Prims.of_int (70))))) + (Prims.of_int (298)) (Prims.of_int (49)) + (Prims.of_int (298)) (Prims.of_int (70))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" @@ -330,8 +350,8 @@ let (ctx_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (293)) (Prims.of_int (42)) - (Prims.of_int (293)) (Prims.of_int (93))))) + (Prims.of_int (304)) (Prims.of_int (42)) + (Prims.of_int (304)) (Prims.of_int (93))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" @@ -342,13 +362,13 @@ let (ctx_to_string : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (293)) (Prims.of_int (64)) - (Prims.of_int (293)) (Prims.of_int (92))))) + (Prims.of_int (304)) (Prims.of_int (64)) + (Prims.of_int (304)) (Prims.of_int (92))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (293)) (Prims.of_int (42)) - (Prims.of_int (293)) (Prims.of_int (93))))) + (Prims.of_int (304)) (Prims.of_int (42)) + (Prims.of_int (304)) (Prims.of_int (93))))) (Obj.magic (FStar_Tactics_Util.map ctxt_elt_to_string c)) (fun uu___1 -> @@ -366,12 +386,12 @@ let (ctxt_to_list : FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (296)) - (Prims.of_int (12)) (Prims.of_int (296)) (Prims.of_int (27))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (307)) + (Prims.of_int (12)) (Prims.of_int (307)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (297)) - (Prims.of_int (2)) (Prims.of_int (297)) (Prims.of_int (30))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (308)) + (Prims.of_int (2)) (Prims.of_int (308)) (Prims.of_int (30))))) (Obj.magic (FStar_Tactics_Unseal.unseal g.ctxt)) (fun uu___ -> (fun ctx -> @@ -382,12 +402,12 @@ let (print_context : FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (300)) - (Prims.of_int (12)) (Prims.of_int (300)) (Prims.of_int (27))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (311)) + (Prims.of_int (12)) (Prims.of_int (311)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (301)) - (Prims.of_int (2)) (Prims.of_int (304)) (Prims.of_int (79))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (312)) + (Prims.of_int (2)) (Prims.of_int (315)) (Prims.of_int (79))))) (Obj.magic (FStar_Tactics_Unseal.unseal g.ctxt)) (fun uu___ -> (fun ctx -> @@ -403,8 +423,8 @@ let (print_context : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (304)) (Prims.of_int (40)) - (Prims.of_int (304)) (Prims.of_int (79))))) + (Prims.of_int (315)) (Prims.of_int (40)) + (Prims.of_int (315)) (Prims.of_int (79))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "prims.fst" @@ -416,17 +436,17 @@ let (print_context : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (304)) + (Prims.of_int (315)) (Prims.of_int (62)) - (Prims.of_int (304)) + (Prims.of_int (315)) (Prims.of_int (78))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (304)) + (Prims.of_int (315)) (Prims.of_int (40)) - (Prims.of_int (304)) + (Prims.of_int (315)) (Prims.of_int (79))))) (Obj.magic (ctxt_to_list g)) (fun uu___1 -> @@ -448,12 +468,12 @@ let (print_issue : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (308)) (Prims.of_int (30)) - (Prims.of_int (310)) (Prims.of_int (37))))) + (Prims.of_int (319)) (Prims.of_int (30)) + (Prims.of_int (321)) (Prims.of_int (37))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) (Prims.of_int (4)) (Prims.of_int (316)) + (Prims.of_int (323)) (Prims.of_int (4)) (Prims.of_int (327)) (Prims.of_int (101))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___1 -> @@ -478,42 +498,42 @@ let (print_issue : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) (Prims.of_int (7)) - (Prims.of_int (316)) (Prims.of_int (101))))) + (Prims.of_int (327)) (Prims.of_int (7)) + (Prims.of_int (327)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) (Prims.of_int (4)) - (Prims.of_int (316)) (Prims.of_int (101))))) + (Prims.of_int (323)) (Prims.of_int (4)) + (Prims.of_int (327)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) (Prims.of_int (22)) - (Prims.of_int (316)) (Prims.of_int (100))))) + (Prims.of_int (327)) (Prims.of_int (22)) + (Prims.of_int (327)) (Prims.of_int (100))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) (Prims.of_int (7)) - (Prims.of_int (316)) (Prims.of_int (101))))) + (Prims.of_int (327)) (Prims.of_int (7)) + (Prims.of_int (327)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (23)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (22)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (100))))) (Obj.magic (FStar_Tactics_Unseal.unseal @@ -526,17 +546,17 @@ let (print_issue : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (50)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (99))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (22)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (100))))) (Obj.magic (FStar_Tactics_Util.map @@ -566,17 +586,17 @@ let (print_issue : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -584,17 +604,17 @@ let (print_issue : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -602,17 +622,17 @@ let (print_issue : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (312)) + (Prims.of_int (323)) (Prims.of_int (4)) - (Prims.of_int (316)) + (Prims.of_int (327)) (Prims.of_int (101))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -620,9 +640,9 @@ let (print_issue : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (313)) + (Prims.of_int (324)) (Prims.of_int (7)) - (Prims.of_int (313)) + (Prims.of_int (324)) (Prims.of_int (47))))) (FStar_Sealed.seal (Obj.magic @@ -682,12 +702,12 @@ let (print_issues : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (320)) (Prims.of_int (24)) - (Prims.of_int (320)) (Prims.of_int (49))))) + (Prims.of_int (331)) (Prims.of_int (24)) + (Prims.of_int (331)) (Prims.of_int (49))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (320)) (Prims.of_int (5)) (Prims.of_int (320)) + (Prims.of_int (331)) (Prims.of_int (5)) (Prims.of_int (331)) (Prims.of_int (49))))) (Obj.magic (FStar_Tactics_Util.map (print_issue g) i)) (fun uu___ -> @@ -699,24 +719,24 @@ let (env_to_string : FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (323)) - (Prims.of_int (11)) (Prims.of_int (325)) (Prims.of_int (24))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (334)) + (Prims.of_int (11)) (Prims.of_int (336)) (Prims.of_int (24))))) (FStar_Sealed.seal (Obj.magic - (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (326)) - (Prims.of_int (2)) (Prims.of_int (326)) (Prims.of_int (25))))) + (FStar_Range.mk_range "Pulse.Typing.Env.fst" (Prims.of_int (337)) + (Prims.of_int (2)) (Prims.of_int (337)) (Prims.of_int (25))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (325)) (Prims.of_int (4)) - (Prims.of_int (325)) (Prims.of_int (24))))) + (Prims.of_int (336)) (Prims.of_int (4)) + (Prims.of_int (336)) (Prims.of_int (24))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (323)) (Prims.of_int (11)) - (Prims.of_int (325)) (Prims.of_int (24))))) + (Prims.of_int (334)) (Prims.of_int (11)) + (Prims.of_int (336)) (Prims.of_int (24))))) (Obj.magic (FStar_Tactics_Util.zip e.bs e.names)) (fun uu___ -> (fun uu___ -> @@ -730,17 +750,17 @@ let (env_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (72)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (24)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (Obj.magic (Pulse_Syntax_Printer.term_to_string t)) @@ -752,17 +772,17 @@ let (env_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (24)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (24)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -770,17 +790,17 @@ let (env_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (24)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (24)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (111))))) (Obj.magic (FStar_Tactics_Effect.tac_bind @@ -788,9 +808,9 @@ let (env_to_string : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (52)) - (Prims.of_int (324)) + (Prims.of_int (335)) (Prims.of_int (69))))) (FStar_Sealed.seal (Obj.magic @@ -843,13 +863,13 @@ let fail : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (330)) (Prims.of_int (4)) - (Prims.of_int (335)) (Prims.of_int (12))))) + (Prims.of_int (341)) (Prims.of_int (4)) + (Prims.of_int (346)) (Prims.of_int (12))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (336)) (Prims.of_int (4)) - (Prims.of_int (339)) (Prims.of_int (31))))) + (Prims.of_int (347)) (Prims.of_int (4)) + (Prims.of_int (350)) (Prims.of_int (31))))) (match r with | FStar_Pervasives_Native.None -> Obj.magic (range_of_env g) | FStar_Pervasives_Native.Some r1 -> @@ -858,13 +878,13 @@ let fail : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (333)) (Prims.of_int (9)) - (Prims.of_int (333)) (Prims.of_int (27))))) + (Prims.of_int (344)) (Prims.of_int (9)) + (Prims.of_int (344)) (Prims.of_int (27))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (333)) (Prims.of_int (6)) - (Prims.of_int (335)) (Prims.of_int (12))))) + (Prims.of_int (344)) (Prims.of_int (6)) + (Prims.of_int (346)) (Prims.of_int (12))))) (FStar_Tactics_Effect.lift_div_tac (fun uu___ -> Pulse_RuntimeUtils.is_range_zero r1)) (fun uu___ -> @@ -883,25 +903,25 @@ let fail : (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (337)) (Prims.of_int (14)) - (Prims.of_int (337)) (Prims.of_int (77))))) + (Prims.of_int (348)) (Prims.of_int (14)) + (Prims.of_int (348)) (Prims.of_int (77))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (338)) (Prims.of_int (2)) - (Prims.of_int (339)) (Prims.of_int (31))))) + (Prims.of_int (349)) (Prims.of_int (2)) + (Prims.of_int (350)) (Prims.of_int (31))))) (Obj.magic (FStar_Tactics_Effect.tac_bind (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (337)) (Prims.of_int (61)) - (Prims.of_int (337)) (Prims.of_int (77))))) + (Prims.of_int (348)) (Prims.of_int (61)) + (Prims.of_int (348)) (Prims.of_int (77))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (337)) (Prims.of_int (14)) - (Prims.of_int (337)) (Prims.of_int (77))))) + (Prims.of_int (348)) (Prims.of_int (14)) + (Prims.of_int (348)) (Prims.of_int (77))))) (Obj.magic (ctxt_to_list g)) (fun uu___ -> FStar_Tactics_Effect.lift_div_tac @@ -917,17 +937,17 @@ let fail : (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (338)) + (Prims.of_int (349)) (Prims.of_int (2)) - (Prims.of_int (338)) + (Prims.of_int (349)) (Prims.of_int (34))))) (FStar_Sealed.seal (Obj.magic (FStar_Range.mk_range "Pulse.Typing.Env.fst" - (Prims.of_int (339)) + (Prims.of_int (350)) (Prims.of_int (2)) - (Prims.of_int (339)) + (Prims.of_int (350)) (Prims.of_int (31))))) (Obj.magic (FStar_Tactics_V1_Builtins.log_issues diff --git a/src/ocaml/plugin/generated/Pulse_Typing_Metatheory.ml b/src/ocaml/plugin/generated/Pulse_Typing_Metatheory.ml index d3cccda53..686f231a9 100644 --- a/src/ocaml/plugin/generated/Pulse_Typing_Metatheory.ml +++ b/src/ocaml/plugin/generated/Pulse_Typing_Metatheory.ml @@ -1,347 +1,39 @@ open Prims -type ('g, 'c) comp_typing_u = (unit, unit, unit) Pulse_Typing.comp_typing -let (admit_st_comp_typing : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_comp -> (unit, unit) Pulse_Typing.st_comp_typing) - = - fun g -> - fun st -> - Pulse_Typing.STC (g, st, (Pulse_Typing_Env.fresh g), (), (), ()) -let (admit_comp_typing : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp_st -> (unit, unit) comp_typing_u) - = - fun g -> - fun c -> - match c with - | Pulse_Syntax_Base.C_ST st -> - Pulse_Typing.CT_ST (g, st, (admit_st_comp_typing g st)) - | Pulse_Syntax_Base.C_STAtomic (inames, st) -> - Pulse_Typing.CT_STAtomic - (g, inames, st, (), (admit_st_comp_typing g st)) - | Pulse_Syntax_Base.C_STGhost (inames, st) -> - Pulse_Typing.CT_STGhost - (g, inames, st, (), (admit_st_comp_typing g st)) -let (st_typing_correctness : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp_st -> - (unit, unit, unit) Pulse_Typing.st_typing -> - (unit, unit) comp_typing_u) - = fun g -> fun t -> fun c -> fun uu___ -> admit_comp_typing g c -let (add_frame_well_typed : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp_st -> - (unit, unit) comp_typing_u -> - Pulse_Syntax_Base.term -> unit -> (unit, unit) comp_typing_u) - = - fun g -> - fun c -> - fun ct -> - fun f -> fun ft -> admit_comp_typing g (Pulse_Typing.add_frame c f) -let (comp_typing_inversion : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp_st -> - (unit, unit) comp_typing_u -> (unit, unit) Pulse_Typing.st_comp_typing) - = - fun g -> - fun c -> - fun ct -> - match ct with - | Pulse_Typing.CT_ST (uu___, uu___1, st) -> st - | Pulse_Typing.CT_STAtomic (uu___, uu___1, uu___2, uu___3, st) -> st - | Pulse_Typing.CT_STGhost (uu___, uu___1, uu___2, uu___3, st) -> st -let (st_comp_typing_inversion_cofinite : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_comp -> - (unit, unit) Pulse_Typing.st_comp_typing -> (unit * unit * unit)) - = fun g -> fun st -> fun ct -> ((), (), ()) -let (st_comp_typing_inversion : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_comp -> - (unit, unit) Pulse_Typing.st_comp_typing -> - (unit, unit, Pulse_Syntax_Base.var, unit) FStar_Pervasives.dtuple4) - = - fun g -> - fun st -> - fun ct -> - let uu___ = ct in - match uu___ with - | Pulse_Typing.STC (g1, st1, x, ty, pre, post) -> - FStar_Pervasives.Mkdtuple4 ((), (), x, ()) -let (tm_exists_inversion : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.term -> - unit -> Pulse_Syntax_Base.var -> (unit * unit)) - = fun g -> fun u -> fun ty -> fun p -> fun uu___ -> fun x -> ((), ()) -type ('g, 'gu, 'guu) pairwise_disjoint = unit - - -let (comp_st_with_post : - Pulse_Syntax_Base.comp_st -> - Pulse_Syntax_Base.term -> Pulse_Syntax_Base.comp_st) - = - fun c -> - fun post -> - match c with - | Pulse_Syntax_Base.C_ST st -> - Pulse_Syntax_Base.C_ST - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = (st.Pulse_Syntax_Base.pre); - Pulse_Syntax_Base.post = post - } - | Pulse_Syntax_Base.C_STGhost (i, st) -> - Pulse_Syntax_Base.C_STGhost - (i, - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = (st.Pulse_Syntax_Base.pre); - Pulse_Syntax_Base.post = post - }) - | Pulse_Syntax_Base.C_STAtomic (i, st) -> - Pulse_Syntax_Base.C_STAtomic - (i, - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = (st.Pulse_Syntax_Base.pre); - Pulse_Syntax_Base.post = post - }) -let (comp_st_with_pre : - Pulse_Syntax_Base.comp_st -> - Pulse_Syntax_Base.term -> Pulse_Syntax_Base.comp_st) - = - fun c -> - fun pre -> - match c with - | Pulse_Syntax_Base.C_ST st -> - Pulse_Syntax_Base.C_ST - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = pre; - Pulse_Syntax_Base.post = (st.Pulse_Syntax_Base.post) - } - | Pulse_Syntax_Base.C_STGhost (i, st) -> - Pulse_Syntax_Base.C_STGhost - (i, - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = pre; - Pulse_Syntax_Base.post = (st.Pulse_Syntax_Base.post) - }) - | Pulse_Syntax_Base.C_STAtomic (i, st) -> - Pulse_Syntax_Base.C_STAtomic - (i, - { - Pulse_Syntax_Base.u = (st.Pulse_Syntax_Base.u); - Pulse_Syntax_Base.res = (st.Pulse_Syntax_Base.res); - Pulse_Syntax_Base.pre = pre; - Pulse_Syntax_Base.post = (st.Pulse_Syntax_Base.post) - }) -let (non_informative_t_weakening : +let (st_typing_weakening : Pulse_Typing_Env.env -> Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.term -> - (unit, unit, unit) Pulse_Typing.non_informative_t -> - (unit, unit, unit) Pulse_Typing.non_informative_t) - = - fun g -> - fun g' -> - fun g1 -> - fun u -> - fun t -> - fun d -> - let uu___ = d in - match uu___ with - | Prims.Mkdtuple2 (w, uu___1) -> Prims.Mkdtuple2 (w, ()) -let (non_informative_c_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp_st -> - (unit, unit) Pulse_Typing.non_informative_c -> - (unit, unit) Pulse_Typing.non_informative_c) - = - fun g -> - fun g' -> - fun g1 -> - fun c -> - fun d -> - non_informative_t_weakening g g' g1 (Pulse_Syntax_Base.comp_u c) - (Pulse_Syntax_Base.comp_res c) d -let (bind_comp_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp -> - Pulse_Typing_Env.env -> - (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp) - = - fun g -> - fun g' -> - fun x -> - fun c1 -> - fun c2 -> - fun c3 -> - fun d -> - fun g1 -> - match d with - | Pulse_Typing.Bind_comp - (uu___, x1, c11, c21, uu___1, uu___2, uu___3) -> - let y = - Pulse_Typing_Env.fresh - (Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g') in - Pulse_Typing.Bind_comp - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), x1, c11, - c21, (), y, ()) - | Pulse_Typing.Bind_comp_ghost_l - (uu___, x1, c11, c21, n_d, uu___1, uu___2, uu___3) -> - let y = - Pulse_Typing_Env.fresh - (Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g') in - Pulse_Typing.Bind_comp_ghost_l - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), x1, c11, - c21, (non_informative_c_weakening g g' g1 c11 n_d), - (), y, ()) - | Pulse_Typing.Bind_comp_ghost_r - (uu___, x1, c11, c21, n_d, uu___1, uu___2, uu___3) -> - let y = - Pulse_Typing_Env.fresh - (Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g') in - Pulse_Typing.Bind_comp_ghost_r - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), x1, c11, - c21, (non_informative_c_weakening g g' g1 c21 n_d), - (), y, ()) -let (lift_comp_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.st_term -> Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.lift_comp -> - Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.lift_comp) + (unit, unit, unit) Pulse_Typing.st_typing -> + Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) = fun g -> fun g' -> - fun c1 -> - fun c2 -> + fun t -> + fun c -> fun d -> fun g1 -> - match d with - | Pulse_Typing.Lift_STAtomic_ST (uu___, c) -> - Pulse_Typing.Lift_STAtomic_ST - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), c) - | Pulse_Typing.Lift_STGhost_STAtomic - (uu___, c, non_informative_c) -> - Pulse_Typing.Lift_STGhost_STAtomic - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), c, - (non_informative_c_weakening g g' g1 c - non_informative_c)) -let (st_equiv_weakening : + let g2 = Pulse_Typing_Env.diff g1 g in + let d1 = + Pulse_Typing_Metatheory_Base.st_typing_weakening g g' t c d + g2 in + d1 +let (st_typing_weakening_standard : Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_term -> Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.st_equiv -> - Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_equiv) - = - fun g -> - fun g' -> - fun c1 -> - fun c2 -> - fun d -> - fun g1 -> - match d with - | Pulse_Typing.ST_VPropEquiv - (uu___, c11, c21, x, uu___1, uu___2, uu___3, uu___4, - uu___5) - -> - Pulse_Typing.ST_VPropEquiv - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), c11, c21, x, - (), (), (), (), ()) -let (st_comp_typing_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.st_comp -> - (unit, unit) Pulse_Typing.st_comp_typing -> - Pulse_Typing_Env.env -> (unit, unit) Pulse_Typing.st_comp_typing) + (unit, unit, unit) Pulse_Typing.st_typing -> + Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) = fun g -> - fun g' -> - fun s -> + fun t -> + fun c -> fun d -> fun g1 -> - match d with - | Pulse_Typing.STC (uu___, st, x, uu___1, uu___2, uu___3) -> - Pulse_Typing.STC - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), st, x, (), (), - ()) -let (comp_typing_weakening : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.universe -> - (unit, unit, unit) Pulse_Typing.comp_typing -> - Pulse_Typing_Env.env -> - (unit, unit, unit) Pulse_Typing.comp_typing) - = - fun g -> - fun g' -> - fun c -> - fun u -> - fun d -> - fun g1 -> - match d with - | Pulse_Typing.CT_Tot (uu___, t, u1, uu___1) -> - Pulse_Typing.CT_Tot - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), t, u1, ()) - | Pulse_Typing.CT_ST (uu___, uu___1, d1) -> - Pulse_Typing.CT_ST - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), uu___1, - (st_comp_typing_weakening g g' uu___1 d1 g1)) - | Pulse_Typing.CT_STAtomic (uu___, inames, uu___1, uu___2, d1) - -> - Pulse_Typing.CT_STAtomic - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), inames, uu___1, - (), (st_comp_typing_weakening g g' uu___1 d1 g1)) - | Pulse_Typing.CT_STGhost (uu___, inames, uu___1, uu___2, d1) - -> - Pulse_Typing.CT_STGhost - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), inames, uu___1, - (), (st_comp_typing_weakening g g' uu___1 d1 g1)) -let (prop_validity_token_weakening : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - (unit, unit) Pulse_Typing.prop_validity -> - Pulse_Typing_Env.env -> (unit, unit) Pulse_Typing.prop_validity) - = fun g -> fun t -> fun token -> fun g1 -> token -let rec (st_typing_weakening : + let g' = Pulse_Typing_Env.mk_env (Pulse_Typing_Env.fstar_env g) in + let d1 = st_typing_weakening g g' t c d g1 in d1 +let (st_typing_weakening_end : Pulse_Typing_Env.env -> Pulse_Typing_Env.env -> Pulse_Syntax_Base.st_term -> @@ -354,794 +46,12 @@ let rec (st_typing_weakening : fun t -> fun c -> fun d -> - fun g1 -> - match d with - | Pulse_Typing.T_Abs - (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, uu___6, - uu___7, uu___8) - -> Prims.magic () - | Pulse_Typing.T_STApp - (uu___, head, ty, q, res, arg, uu___1, uu___2) -> - Pulse_Typing.T_STApp - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), head, ty, q, - res, arg, (), ()) - | Pulse_Typing.T_Return - (uu___, c1, use_eq, u, t1, e, post, x_old, uu___1, uu___2, - uu___3) - -> - let x = - Pulse_Typing_Env.fresh - (Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g') in - Pulse_Typing.T_Return - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), c1, use_eq, u, - t1, e, post, x, (), (), ()) - | Pulse_Typing.T_Lift (uu___, e, c1, c2, d_c1, d_lift) -> - Pulse_Typing.T_Lift - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), e, c1, c2, - (st_typing_weakening g g' e c1 d_c1 g1), - (lift_comp_weakening g g' c1 c2 d_lift g1)) - | Pulse_Typing.T_Bind - (uu___, e1, e2, c1, c2, b, x, c3, d_e1, uu___1, d_e2, d_bc) - -> - let d_e11 = st_typing_weakening g g' e1 c1 d_e1 g1 in - let d_e21 = d_e2 in - let d_e22 = d_e21 in - let d_e23 = - st_typing_weakening g - (Pulse_Typing_Env.push_binding g' x - Pulse_Syntax_Base.ppname_default - (Pulse_Syntax_Base.comp_res c1)) - (Pulse_Syntax_Naming.open_st_term_nv e2 - ((b.Pulse_Syntax_Base.binder_ppname), x)) c2 d_e22 - g1 in - let d_e24 = d_e23 in - let d_bc1 = bind_comp_weakening g g' x c1 c2 c3 d_bc g1 in - Pulse_Typing.T_Bind - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), e1, e2, c1, c2, - b, x, c3, d_e11, (), d_e24, d_bc1) - | Pulse_Typing.T_TotBind - (uu___, e1, e2, t1, c2, x, uu___1, d_e2) -> - let d_e21 = d_e2 in - let d_e22 = d_e21 in - let d_e23 = - st_typing_weakening g - (Pulse_Typing_Env.push_binding g' x - Pulse_Syntax_Base.ppname_default t1) - (Pulse_Syntax_Naming.open_st_term_nv e2 - (Pulse_Syntax_Base.v_as_nv x)) c2 d_e22 g1 in - let d_e24 = d_e23 in - Pulse_Typing.T_TotBind - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), e1, e2, t1, c2, - x, (), d_e24) - | Pulse_Typing.T_If - (uu___, b, e1, e2, c1, uc, hyp, uu___1, d_e1, d_e2, uu___2) - -> - let d_e11 = d_e1 in - let d_e12 = d_e11 in - let d_e13 = - st_typing_weakening g - (Pulse_Typing_Env.push_binding g' hyp - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_eq2 Pulse_Syntax_Pure.u0 - Pulse_Typing.tm_bool b Pulse_Typing.tm_true)) e1 - c1 d_e12 g1 in - let d_e14 = d_e13 in - let d_e21 = d_e2 in - let d_e22 = d_e21 in - let d_e23 = - st_typing_weakening g - (Pulse_Typing_Env.push_binding g' hyp - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_eq2 Pulse_Syntax_Pure.u0 - Pulse_Typing.tm_bool b Pulse_Typing.tm_false)) e2 - c1 d_e22 g1 in - let d_e24 = d_e23 in - Pulse_Typing.T_If - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), b, e1, e2, c1, - uc, hyp, (), d_e14, d_e24, ()) - | Pulse_Typing.T_Match - (uu___, sc_u, sc_ty, sc, d_sc_ty, d_sc, c1, brs, d_brs, - d_pats_complete) - -> - Pulse_Typing.T_Match - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), sc_u, sc_ty, - sc, (), (), c1, brs, - (weaken_brs_typing g g' g1 sc_u sc_ty sc brs c1 d_brs), - d_pats_complete) - | Pulse_Typing.T_Frame (uu___, e, c1, frame, uu___1, d_e) -> - Pulse_Typing.T_Frame - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), e, c1, frame, - (), (st_typing_weakening g g' e c1 d_e g1)) - | Pulse_Typing.T_Equiv (uu___, e, c1, c', d_e, d_eq) -> - Pulse_Typing.T_Equiv - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), e, c1, c', - (st_typing_weakening g g' e c1 d_e g1), - (st_equiv_weakening g g' c1 c' d_eq g1)) - | Pulse_Typing.T_IntroPure (uu___, p, uu___1, token) -> - Pulse_Typing.T_IntroPure - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), p, (), - (prop_validity_token_weakening uu___ p token - (Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'))) - | Pulse_Typing.T_ElimExists - (uu___, u, t1, p, x, uu___1, uu___2) -> - Pulse_Typing.T_ElimExists - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), u, t1, p, x, - (), ()) - | Pulse_Typing.T_IntroExists - (uu___, u, b, p, e, uu___1, uu___2, uu___3) -> - Pulse_Typing.T_IntroExists - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), u, b, p, e, (), - (), ()) - | Pulse_Typing.T_IntroExistsErased - (uu___, u, b, p, e, uu___1, uu___2, uu___3) -> - Pulse_Typing.T_IntroExistsErased - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), u, b, p, e, (), - (), ()) - | Pulse_Typing.T_While - (uu___, inv, cond, body, uu___1, cond_typing, body_typing) - -> - Pulse_Typing.T_While - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), inv, cond, - body, (), - (st_typing_weakening g g' cond - (Pulse_Typing.comp_while_cond - Pulse_Syntax_Base.ppname_default inv) cond_typing - g1), - (st_typing_weakening g g' body - (Pulse_Typing.comp_while_body - Pulse_Syntax_Base.ppname_default inv) body_typing - g1)) - | Pulse_Typing.T_Par - (uu___, eL, cL, eR, cR, x, cL_typing, cR_typing, eL_typing, - eR_typing) - -> - Pulse_Typing.T_Par - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), eL, cL, eR, cR, - x, - (comp_typing_weakening g g' cL - (Pulse_Syntax_Base.comp_u cL) cL_typing g1), - (comp_typing_weakening g g' cR - (Pulse_Syntax_Base.comp_u cR) cR_typing g1), - (st_typing_weakening g g' eL cL eL_typing g1), - (st_typing_weakening g g' eR cR eR_typing g1)) - | Pulse_Typing.T_WithLocal - (uu___, init, body, init_t, c1, x, uu___1, uu___2, d_c, - d_body) - -> - let d_body1 = d_body in - let d_body2 = d_body1 in - let d_body3 = - st_typing_weakening g - (Pulse_Typing_Env.push_binding g' x - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_ref init_t)) - (Pulse_Syntax_Naming.open_st_term_nv body - (Pulse_Syntax_Base.v_as_nv x)) - (Pulse_Typing.comp_withlocal_body x init_t init c1) - d_body2 g1 in - let d_body4 = d_body3 in - Pulse_Typing.T_WithLocal - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), init, body, - init_t, c1, x, (), (), - (comp_typing_weakening g g' c1 - (Pulse_Syntax_Base.comp_u c1) d_c g1), d_body4) - | Pulse_Typing.T_Rewrite (uu___, p, q, uu___1, uu___2) -> - Pulse_Typing.T_Rewrite - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), p, q, (), ()) - | Pulse_Typing.T_Admit (uu___, s, c1, d_s) -> - Pulse_Typing.T_Admit - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), s, c1, - (st_comp_typing_weakening g g' s d_s g1)) -and (weaken_brs_typing : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.typ -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.branch Prims.list -> - Pulse_Syntax_Base.comp_st -> - (unit, unit, unit, unit, unit, unit) - Pulse_Typing.brs_typing -> - (unit, unit, unit, unit, unit, unit) - Pulse_Typing.brs_typing) - = - fun g -> - fun g' -> - fun g1 -> - fun sc_u -> - fun sc_ty -> - fun sc -> - fun brs -> - fun c -> - fun d -> - match d with - | Pulse_Typing.TBRS_0 c1 -> Pulse_Typing.TBRS_0 c1 - | Pulse_Typing.TBRS_1 (c1, p, e, brd, rest, rest_d) -> - Pulse_Typing.TBRS_1 - (c1, p, e, - (weaken_br_typing g g' g1 sc_u sc_ty sc p e c1 - brd), rest, - (weaken_brs_typing g g' g1 sc_u sc_ty sc rest c1 - rest_d)) -and (weaken_br_typing : - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.typ -> - Pulse_Syntax_Base.term -> - Pulse_Syntax_Base.pattern -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp_st -> - (unit, unit, unit, unit, unit, unit, unit) - Pulse_Typing.br_typing -> - (unit, unit, unit, unit, unit, unit, unit) - Pulse_Typing.br_typing) - = - fun g -> - fun g' -> - fun g1 -> - fun sc_u -> - fun sc_ty -> - fun sc -> - fun p -> - fun e -> - fun c -> - fun d -> - let uu___ = d in - match uu___ with - | Pulse_Typing.TBR - (uu___1, sc_u1, sc_ty1, sc1, c1, p1, e1, bs, - uu___2, uu___3, uu___4, hyp, d1) - -> - Pulse_Typing.TBR - ((Pulse_Typing_Env.push_env - (Pulse_Typing_Env.push_env g g1) g'), sc_u1, - sc_ty1, sc1, c1, p1, e1, bs, (), (), (), hyp, - (st_typing_weakening g g' e1 c1 d1 g1)) -let (singleton_env : - FStar_Reflection_Typing.fstar_top_env -> - Pulse_Syntax_Base.var -> Pulse_Syntax_Base.typ -> Pulse_Typing_Env.env) - = - fun f -> - fun x -> - fun t -> - Pulse_Typing_Env.push_binding (Pulse_Typing_Env.mk_env f) x - Pulse_Syntax_Base.ppname_default t -let (nt : - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.term -> Pulse_Syntax_Naming.subst_elt Prims.list) - = fun x -> fun t -> [Pulse_Syntax_Naming.NT (x, t)] -let rec (subst_env : - Pulse_Typing_Env.env -> Pulse_Syntax_Naming.subst -> Pulse_Typing_Env.env) - = - fun en -> - fun ss -> - match Pulse_Typing_Env.bindings en with - | [] -> en - | uu___ -> - let uu___1 = Pulse_Typing_Env.remove_latest_binding en in - (match uu___1 with - | (x, t, en1) -> - Pulse_Typing_Env.push_binding (subst_env en1 ss) x - Pulse_Syntax_Base.ppname_default - (Pulse_Syntax_Naming.subst_term t ss)) -let (non_informative_t_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.universe -> - Pulse_Syntax_Base.term -> - (unit, unit, unit) Pulse_Typing.non_informative_t -> - (unit, unit, unit) Pulse_Typing.non_informative_t) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun u -> - fun t1 -> - fun d -> - let ss = nt x e in - let uu___ = d in - match uu___ with - | Prims.Mkdtuple2 (w, uu___1) -> - Prims.Mkdtuple2 - ((Pulse_Syntax_Naming.subst_term w ss), ()) -let (non_informative_c_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.comp -> - (unit, unit) Pulse_Typing.non_informative_c -> - (unit, unit) Pulse_Typing.non_informative_c) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun c -> - fun d -> - non_informative_t_subst g x t g' e () - (Pulse_Syntax_Base.comp_u c) - (Pulse_Syntax_Base.comp_res c) d -let (lift_comp_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.lift_comp -> - (unit, unit, unit) Pulse_Typing.lift_comp) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun c1 -> - fun c2 -> - fun d -> - let ss = nt x e in - match d with - | Pulse_Typing.Lift_STAtomic_ST (uu___, c) -> - Pulse_Typing.Lift_STAtomic_ST - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_comp c ss)) - | Pulse_Typing.Lift_STGhost_STAtomic - (uu___, c, d_non_informative) -> - Pulse_Typing.Lift_STGhost_STAtomic - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_comp c ss), - (non_informative_c_subst g x t g' e () c - d_non_informative)) -let (bind_comp_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp - -> - (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun y -> - fun c1 -> - fun c2 -> - fun c3 -> - fun d -> - let ss = nt x e in - match d with - | Pulse_Typing.Bind_comp - (uu___, y1, c11, c21, uu___1, z, uu___2) -> - Pulse_Typing.Bind_comp - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), y1, - (Pulse_Syntax_Naming.subst_comp c11 ss), - (Pulse_Syntax_Naming.subst_comp c21 ss), (), - z, ()) - | Pulse_Typing.Bind_comp_ghost_l - (uu___, y1, c11, c21, d_non_informative, uu___1, - z, uu___2) - -> - Pulse_Typing.Bind_comp_ghost_l - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), y1, - (Pulse_Syntax_Naming.subst_comp c11 ss), - (Pulse_Syntax_Naming.subst_comp c21 ss), - (non_informative_c_subst g x t g' e () c11 - d_non_informative), (), z, ()) - | Pulse_Typing.Bind_comp_ghost_r - (uu___, y1, c11, c21, d_non_informative, uu___1, - z, uu___2) - -> - Pulse_Typing.Bind_comp_ghost_r - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), y1, - (Pulse_Syntax_Naming.subst_comp c11 ss), - (Pulse_Syntax_Naming.subst_comp c21 ss), - (non_informative_c_subst g x t g' e () c21 - d_non_informative), (), z, ()) -let (st_equiv_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.comp -> - (unit, unit, unit) Pulse_Typing.st_equiv -> - (unit, unit, unit) Pulse_Typing.st_equiv) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun c1 -> - fun c2 -> - fun d -> - match d with - | Pulse_Typing.ST_VPropEquiv - (uu___, c11, c21, y, uu___1, uu___2, uu___3, uu___4, - uu___5) - -> - Pulse_Typing.ST_VPropEquiv - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_comp c11 (nt x e)), - (Pulse_Syntax_Naming.subst_comp c21 (nt x e)), y, - (), (), (), (), ()) -let (st_comp_typing_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.st_comp -> - (unit, unit) Pulse_Typing.st_comp_typing -> - (unit, unit) Pulse_Typing.st_comp_typing) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun s -> - fun d -> - match d with - | Pulse_Typing.STC (uu___, s1, y, uu___1, uu___2, uu___3) - -> - Pulse_Typing.STC - ((Pulse_Typing_Env.push_env g (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_comp s1 (nt x e)), y, - (), (), ()) -let (comp_typing_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.comp -> - Pulse_Syntax_Base.universe -> - (unit, unit, unit) Pulse_Typing.comp_typing -> - (unit, unit, unit) Pulse_Typing.comp_typing) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun c -> - fun u -> - fun d -> - match d with - | Pulse_Typing.CT_Tot (uu___, t1, u1, uu___1) -> - Pulse_Typing.CT_Tot - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term t1 (nt x e)), u1, - ()) - | Pulse_Typing.CT_ST (uu___, s, d_s) -> - Pulse_Typing.CT_ST - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), - (st_comp_typing_subst g x t g' e () s d_s)) - | Pulse_Typing.CT_STAtomic - (uu___, inames, s, uu___1, d_s) -> - Pulse_Typing.CT_STAtomic - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), inames, - (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), - (), (st_comp_typing_subst g x t g' e () s d_s)) - | Pulse_Typing.CT_STGhost (uu___, inames, s, uu___1, d_s) - -> - Pulse_Typing.CT_STGhost - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), inames, - (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), - (), (st_comp_typing_subst g x t g' e () s d_s)) -let coerce_eq : 'a 'b . 'a -> unit -> 'b = - fun uu___1 -> fun uu___ -> (fun x -> fun uu___ -> Obj.magic x) uu___1 uu___ -let rec (st_typing_subst : - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.var -> - Pulse_Syntax_Base.typ -> - Pulse_Typing_Env.env -> - Pulse_Syntax_Base.term -> - unit -> - Pulse_Syntax_Base.st_term -> - Pulse_Syntax_Base.comp_st -> - (unit, unit, unit) Pulse_Typing.st_typing -> - (unit, unit, unit) Pulse_Typing.st_typing) - = - fun g -> - fun x -> - fun t -> - fun g' -> - fun e -> - fun e_typing -> - fun e1 -> - fun c1 -> - fun e1_typing -> - let ss = nt x e in - match e1_typing with - | Pulse_Typing.T_Abs - (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, - uu___6, uu___7, uu___8) - -> Prims.magic () - | Pulse_Typing.T_STApp - (uu___, head, ty, q, res, arg, uu___1, uu___2) -> - Pulse_Typing.T_STApp - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term head ss), - (Pulse_Syntax_Naming.subst_term ty ss), q, - (Pulse_Syntax_Naming.subst_comp res ss), - (Pulse_Syntax_Naming.subst_term arg ss), (), ()) - | Pulse_Typing.T_Return - (uu___, c, use_eq, u, t1, e2, post, x1, uu___1, - uu___2, uu___3) - -> - Pulse_Typing.T_Return - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), c, use_eq, u, - (Pulse_Syntax_Naming.subst_term t1 ss), - (Pulse_Syntax_Naming.subst_term e2 ss), - (Pulse_Syntax_Naming.subst_term post ss), x1, (), - (), ()) - | Pulse_Typing.T_Lift (uu___, e2, c11, c2, d_e, d_lift) - -> - Pulse_Typing.T_Lift - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_comp c11 ss), - (Pulse_Syntax_Naming.subst_comp c2 ss), - (st_typing_subst g x t g' e () e2 c11 d_e), - (lift_comp_subst g x t g' e () c11 c2 d_lift)) - | Pulse_Typing.T_Bind - (uu___, e11, e2, c11, c2, b, y, c, d_e1, uu___1, - d_e2, d_bc) - -> - Pulse_Typing.T_Bind - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_term e11 ss), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_comp c11 ss), - (Pulse_Syntax_Naming.subst_comp c2 ss), - (Pulse_Syntax_Naming.subst_binder b ss), y, - (Pulse_Syntax_Naming.subst_comp c ss), - (st_typing_subst g x t g' e () e11 c11 d_e1), (), - (coerce_eq - (st_typing_subst g x t - (Pulse_Typing_Env.push_binding g' y - Pulse_Syntax_Base.ppname_default - (Pulse_Syntax_Base.comp_res c11)) e () - (Pulse_Syntax_Naming.open_st_term_nv e2 - ((b.Pulse_Syntax_Base.binder_ppname), y)) - c2 d_e2) ()), - (bind_comp_subst g x t g' e () y c11 c2 c d_bc)) - | Pulse_Typing.T_TotBind - (uu___, e11, e2, t1, c2, y, uu___1, d_e2) -> - Pulse_Typing.T_TotBind - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term e11 ss), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_term t1 ss), - (Pulse_Syntax_Naming.subst_comp c2 ss), y, (), - (coerce_eq - (st_typing_subst g x t - (Pulse_Typing_Env.push_binding g' y - Pulse_Syntax_Base.ppname_default t1) e - () - (Pulse_Syntax_Naming.open_st_term_nv e2 - (Pulse_Syntax_Base.v_as_nv y)) c2 d_e2) - ())) - | Pulse_Typing.T_If - (uu___, b, e11, e2, c, uc, hyp, uu___1, d_e1, d_e2, - uu___2) - -> - Pulse_Typing.T_If - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term b ss), - (Pulse_Syntax_Naming.subst_st_term e11 ss), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_comp c ss), uc, hyp, - (), - (coerce_eq - (st_typing_subst g x t - (Pulse_Typing_Env.push_binding g' hyp - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_eq2 - Pulse_Syntax_Pure.u0 - Pulse_Typing.tm_bool b - Pulse_Typing.tm_true)) e () e11 c - d_e1) ()), - (coerce_eq - (st_typing_subst g x t - (Pulse_Typing_Env.push_binding g' hyp - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_eq2 - Pulse_Syntax_Pure.u0 - Pulse_Typing.tm_bool b - Pulse_Typing.tm_false)) e () e2 c - d_e2) ()), ()) - | Pulse_Typing.T_Match - (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, - uu___6, uu___7, uu___8, uu___9) - -> Prims.magic () - | Pulse_Typing.T_Frame (uu___, e2, c, frame, uu___1, d_e) - -> - Pulse_Typing.T_Frame - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_comp c ss), - (Pulse_Syntax_Naming.subst_term frame ss), (), - (st_typing_subst g x t g' e () e2 c d_e)) - | Pulse_Typing.T_Equiv (uu___, e2, c, c', d_e, d_eq) -> - Pulse_Typing.T_Equiv - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_term e2 ss), - (Pulse_Syntax_Naming.subst_comp c ss), - (Pulse_Syntax_Naming.subst_comp c' ss), - (st_typing_subst g x t g' e () e2 c d_e), - (st_equiv_subst g x t g' e () c c' d_eq)) - | Pulse_Typing.T_IntroPure (uu___, p, uu___1, uu___2) -> - Pulse_Typing.T_IntroPure - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term p ss), (), - (Prims.magic ())) - | Pulse_Typing.T_ElimExists - (uu___, u, t1, p, y, uu___1, uu___2) -> - Pulse_Typing.T_ElimExists - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), u, - (Pulse_Syntax_Naming.subst_term t1 ss), - (Pulse_Syntax_Naming.subst_term p ss), y, (), ()) - | Pulse_Typing.T_IntroExists - (uu___, u, b, p, e2, uu___1, uu___2, uu___3) -> - Pulse_Typing.T_IntroExists - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), u, - (Pulse_Syntax_Naming.subst_binder b ss), - (Pulse_Syntax_Naming.subst_term p ss), - (Pulse_Syntax_Naming.subst_term e2 ss), (), (), - ()) - | Pulse_Typing.T_IntroExistsErased - (uu___, u, b, p, e2, uu___1, uu___2, uu___3) -> - Pulse_Typing.T_IntroExistsErased - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), u, - (Pulse_Syntax_Naming.subst_binder b ss), - (Pulse_Syntax_Naming.subst_term p ss), - (Pulse_Syntax_Naming.subst_term e2 ss), (), (), - ()) - | Pulse_Typing.T_While - (uu___, inv, cond, body, uu___1, cond_typing, - body_typing) - -> - Pulse_Typing.T_While - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term inv ss), - (Pulse_Syntax_Naming.subst_st_term cond ss), - (Pulse_Syntax_Naming.subst_st_term body ss), (), - (st_typing_subst g x t g' e () cond - (Pulse_Typing.comp_while_cond - Pulse_Syntax_Base.ppname_default inv) - cond_typing), - (st_typing_subst g x t g' e () body - (Pulse_Typing.comp_while_body - Pulse_Syntax_Base.ppname_default inv) - body_typing)) - | Pulse_Typing.T_Par - (uu___, eL, cL, eR, cR, y, d_cL, d_cR, d_eL, d_eR) -> - Pulse_Typing.T_Par - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_term eL ss), - (Pulse_Syntax_Naming.subst_comp cL ss), - (Pulse_Syntax_Naming.subst_st_term eR ss), - (Pulse_Syntax_Naming.subst_comp cR ss), y, - (comp_typing_subst g x t g' e () cL - (Pulse_Syntax_Base.comp_u cL) d_cL), - (comp_typing_subst g x t g' e () cR - (Pulse_Syntax_Base.comp_u cR) d_cR), - (st_typing_subst g x t g' e () eL cL d_eL), - (st_typing_subst g x t g' e () eR cR d_eR)) - | Pulse_Typing.T_WithLocal - (uu___, init, body, init_t, c, y, uu___1, uu___2, - d_c, d_body) - -> - Pulse_Typing.T_WithLocal - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term init ss), - (Pulse_Syntax_Naming.subst_st_term body ss), - (Pulse_Syntax_Naming.subst_term init_t ss), - (Pulse_Syntax_Naming.subst_comp c ss), y, (), (), - (comp_typing_subst g x t g' e () c - (Pulse_Syntax_Base.comp_u c) d_c), - (coerce_eq - (st_typing_subst g x t - (Pulse_Typing_Env.push_binding g' y - Pulse_Syntax_Base.ppname_default - (Pulse_Typing.mk_ref init_t)) e () - (Pulse_Syntax_Naming.open_st_term_nv body - (Pulse_Syntax_Base.v_as_nv y)) - (Pulse_Typing.comp_withlocal_body y init_t - init c) d_body) ())) - | Pulse_Typing.T_Rewrite (uu___, p, q, uu___1, uu___2) -> - Pulse_Typing.T_Rewrite - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_term p ss), - (Pulse_Syntax_Naming.subst_term q ss), (), ()) - | Pulse_Typing.T_Admit (uu___, s, c, d_s) -> - Pulse_Typing.T_Admit - ((Pulse_Typing_Env.push_env g - (subst_env g' (nt x e))), - (Pulse_Syntax_Naming.subst_st_comp s ss), c, - (st_comp_typing_subst g x t g' e () s d_s)) \ No newline at end of file + fun g'' -> + let g2 = Pulse_Typing_Env.diff g'' g' in + let emp_env = + Pulse_Typing_Env.mk_env (Pulse_Typing_Env.fstar_env g) in + let d1 = + Pulse_Typing_Metatheory_Base.st_typing_weakening + (Pulse_Typing_Env.push_env g g') emp_env t c + (FStar_Pervasives.coerce_eq () d) g2 in + FStar_Pervasives.coerce_eq () d1 \ No newline at end of file diff --git a/src/ocaml/plugin/generated/Pulse_Typing_Metatheory_Base.ml b/src/ocaml/plugin/generated/Pulse_Typing_Metatheory_Base.ml new file mode 100644 index 000000000..e831126f9 --- /dev/null +++ b/src/ocaml/plugin/generated/Pulse_Typing_Metatheory_Base.ml @@ -0,0 +1,986 @@ +open Prims +type ('g, 'c) comp_typing_u = (unit, unit, unit) Pulse_Typing.comp_typing +let (admit_st_comp_typing : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_comp -> (unit, unit) Pulse_Typing.st_comp_typing) + = + fun g -> + fun st -> + Pulse_Typing.STC (g, st, (Pulse_Typing_Env.fresh g), (), (), ()) +let (admit_comp_typing : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp_st -> (unit, unit) comp_typing_u) + = + fun g -> + fun c -> + match c with + | Pulse_Syntax_Base.C_ST st -> + Pulse_Typing.CT_ST (g, st, (admit_st_comp_typing g st)) + | Pulse_Syntax_Base.C_STAtomic (inames, st) -> + Pulse_Typing.CT_STAtomic + (g, inames, st, (), (admit_st_comp_typing g st)) + | Pulse_Syntax_Base.C_STGhost (inames, st) -> + Pulse_Typing.CT_STGhost + (g, inames, st, (), (admit_st_comp_typing g st)) +let (st_typing_correctness : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_term -> + Pulse_Syntax_Base.comp_st -> + (unit, unit, unit) Pulse_Typing.st_typing -> + (unit, unit) comp_typing_u) + = fun g -> fun t -> fun c -> fun uu___ -> admit_comp_typing g c +let (add_frame_well_typed : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp_st -> + (unit, unit) comp_typing_u -> + Pulse_Syntax_Base.term -> unit -> (unit, unit) comp_typing_u) + = + fun g -> + fun c -> + fun ct -> + fun f -> fun ft -> admit_comp_typing g (Pulse_Typing.add_frame c f) +let (comp_typing_inversion : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp_st -> + (unit, unit) comp_typing_u -> (unit, unit) Pulse_Typing.st_comp_typing) + = + fun g -> + fun c -> + fun ct -> + match ct with + | Pulse_Typing.CT_ST (uu___, uu___1, st) -> st + | Pulse_Typing.CT_STAtomic (uu___, uu___1, uu___2, uu___3, st) -> st + | Pulse_Typing.CT_STGhost (uu___, uu___1, uu___2, uu___3, st) -> st +let (st_comp_typing_inversion_cofinite : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_comp -> + (unit, unit) Pulse_Typing.st_comp_typing -> (unit * unit * unit)) + = fun g -> fun st -> fun ct -> ((), (), ()) +let (st_comp_typing_inversion : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_comp -> + (unit, unit) Pulse_Typing.st_comp_typing -> + (unit, unit, Pulse_Syntax_Base.var, unit) FStar_Pervasives.dtuple4) + = + fun g -> + fun st -> + fun ct -> + let uu___ = ct in + match uu___ with + | Pulse_Typing.STC (g1, st1, x, ty, pre, post) -> + FStar_Pervasives.Mkdtuple4 ((), (), x, ()) +let (tm_exists_inversion : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.universe -> + Pulse_Syntax_Base.term -> + Pulse_Syntax_Base.term -> + unit -> Pulse_Syntax_Base.var -> (unit * unit)) + = fun g -> fun u -> fun ty -> fun p -> fun uu___ -> fun x -> ((), ()) + + +let (non_informative_t_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.universe -> + Pulse_Syntax_Base.term -> + (unit, unit, unit) Pulse_Typing.non_informative_t -> + (unit, unit, unit) Pulse_Typing.non_informative_t) + = + fun g -> + fun g' -> + fun g1 -> + fun u -> + fun t -> + fun d -> + let uu___ = d in + match uu___ with + | Prims.Mkdtuple2 (w, uu___1) -> Prims.Mkdtuple2 (w, ()) +let (non_informative_c_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp_st -> + (unit, unit) Pulse_Typing.non_informative_c -> + (unit, unit) Pulse_Typing.non_informative_c) + = + fun g -> + fun g' -> + fun g1 -> + fun c -> + fun d -> + non_informative_t_weakening g g' g1 (Pulse_Syntax_Base.comp_u c) + (Pulse_Syntax_Base.comp_res c) d +let (bind_comp_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp -> + Pulse_Typing_Env.env -> + (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp) + = + fun g -> + fun g' -> + fun x -> + fun c1 -> + fun c2 -> + fun c3 -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.Bind_comp + (uu___, x1, c11, c21, uu___1, uu___2, uu___3) -> + let y = + Pulse_Typing_Env.fresh + (Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g') in + Pulse_Typing.Bind_comp + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), x1, c11, + c21, (), y, ()) + | Pulse_Typing.Bind_comp_ghost_l + (uu___, x1, c11, c21, n_d, uu___1, uu___2, uu___3) -> + let y = + Pulse_Typing_Env.fresh + (Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g') in + Pulse_Typing.Bind_comp_ghost_l + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), x1, c11, + c21, (non_informative_c_weakening g g' g1 c11 n_d), + (), y, ()) + | Pulse_Typing.Bind_comp_ghost_r + (uu___, x1, c11, c21, n_d, uu___1, uu___2, uu___3) -> + let y = + Pulse_Typing_Env.fresh + (Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g') in + Pulse_Typing.Bind_comp_ghost_r + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), x1, c11, + c21, (non_informative_c_weakening g g' g1 c21 n_d), + (), y, ()) +let (lift_comp_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit) Pulse_Typing.lift_comp -> + Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.lift_comp) + = + fun g -> + fun g' -> + fun c1 -> + fun c2 -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.Lift_STAtomic_ST (uu___, c) -> + Pulse_Typing.Lift_STAtomic_ST + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), c) + | Pulse_Typing.Lift_STGhost_STAtomic + (uu___, c, non_informative_c) -> + Pulse_Typing.Lift_STGhost_STAtomic + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), c, + (non_informative_c_weakening g g' g1 c + non_informative_c)) +let (st_equiv_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit) Pulse_Typing.st_equiv -> + Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_equiv) + = + fun g -> + fun g' -> + fun c1 -> + fun c2 -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.ST_VPropEquiv + (uu___, c11, c21, x, uu___1, uu___2, uu___3, uu___4, + uu___5) + -> + Pulse_Typing.ST_VPropEquiv + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), c11, c21, x, + (), (), (), (), ()) +let (st_comp_typing_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_comp -> + (unit, unit) Pulse_Typing.st_comp_typing -> + Pulse_Typing_Env.env -> (unit, unit) Pulse_Typing.st_comp_typing) + = + fun g -> + fun g' -> + fun s -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.STC (uu___, st, x, uu___1, uu___2, uu___3) -> + Pulse_Typing.STC + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), st, x, (), (), + ()) +let (comp_typing_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.universe -> + (unit, unit, unit) Pulse_Typing.comp_typing -> + Pulse_Typing_Env.env -> + (unit, unit, unit) Pulse_Typing.comp_typing) + = + fun g -> + fun g' -> + fun c -> + fun u -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.CT_Tot (uu___, t, u1, uu___1) -> + Pulse_Typing.CT_Tot + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), t, u1, ()) + | Pulse_Typing.CT_ST (uu___, uu___1, d1) -> + Pulse_Typing.CT_ST + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), uu___1, + (st_comp_typing_weakening g g' uu___1 d1 g1)) + | Pulse_Typing.CT_STAtomic (uu___, inames, uu___1, uu___2, d1) + -> + Pulse_Typing.CT_STAtomic + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), inames, uu___1, + (), (st_comp_typing_weakening g g' uu___1 d1 g1)) + | Pulse_Typing.CT_STGhost (uu___, inames, uu___1, uu___2, d1) + -> + Pulse_Typing.CT_STGhost + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), inames, uu___1, + (), (st_comp_typing_weakening g g' uu___1 d1 g1)) +let (prop_validity_token_weakening : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + (unit, unit) Pulse_Typing.prop_validity -> + Pulse_Typing_Env.env -> (unit, unit) Pulse_Typing.prop_validity) + = fun g -> fun t -> fun token -> fun g1 -> token +let rec (st_typing_weakening : + Pulse_Typing_Env.env -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.st_term -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit) Pulse_Typing.st_typing -> + Pulse_Typing_Env.env -> (unit, unit, unit) Pulse_Typing.st_typing) + = + fun g -> + fun g' -> + fun t -> + fun c -> + fun d -> + fun g1 -> + match d with + | Pulse_Typing.T_Abs + (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, uu___6, + uu___7, uu___8) + -> Prims.magic () + | Pulse_Typing.T_STApp + (uu___, head, ty, q, res, arg, uu___1, uu___2) -> + Pulse_Typing.T_STApp + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), head, ty, q, + res, arg, (), ()) + | Pulse_Typing.T_Return + (uu___, c1, use_eq, u, t1, e, post, x_old, uu___1, uu___2, + uu___3) + -> + let x = + Pulse_Typing_Env.fresh + (Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g') in + Pulse_Typing.T_Return + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), c1, use_eq, u, + t1, e, post, x, (), (), ()) + | Pulse_Typing.T_Lift (uu___, e, c1, c2, d_c1, d_lift) -> + Pulse_Typing.T_Lift + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), e, c1, c2, + (st_typing_weakening g g' e c1 d_c1 g1), + (lift_comp_weakening g g' c1 c2 d_lift g1)) + | Pulse_Typing.T_Bind + (uu___, e1, e2, c1, c2, b, x, c3, d_e1, uu___1, d_e2, d_bc) + -> + let d_e11 = st_typing_weakening g g' e1 c1 d_e1 g1 in + let d_e21 = d_e2 in + let d_e22 = d_e21 in + let d_e23 = + st_typing_weakening g + (Pulse_Typing_Env.push_binding g' x + Pulse_Syntax_Base.ppname_default + (Pulse_Syntax_Base.comp_res c1)) + (Pulse_Syntax_Naming.open_st_term_nv e2 + ((b.Pulse_Syntax_Base.binder_ppname), x)) c2 d_e22 + g1 in + let d_e24 = d_e23 in + let d_bc1 = bind_comp_weakening g g' x c1 c2 c3 d_bc g1 in + Pulse_Typing.T_Bind + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), e1, e2, c1, c2, + b, x, c3, d_e11, (), d_e24, d_bc1) + | Pulse_Typing.T_TotBind + (uu___, e1, e2, t1, c2, x, uu___1, d_e2) -> + let d_e21 = d_e2 in + let d_e22 = d_e21 in + let d_e23 = + st_typing_weakening g + (Pulse_Typing_Env.push_binding g' x + Pulse_Syntax_Base.ppname_default t1) + (Pulse_Syntax_Naming.open_st_term_nv e2 + (Pulse_Syntax_Base.v_as_nv x)) c2 d_e22 g1 in + let d_e24 = d_e23 in + Pulse_Typing.T_TotBind + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), e1, e2, t1, c2, + x, (), d_e24) + | Pulse_Typing.T_If + (uu___, b, e1, e2, c1, uc, hyp, uu___1, d_e1, d_e2, uu___2) + -> + let d_e11 = d_e1 in + let d_e12 = d_e11 in + let d_e13 = + st_typing_weakening g + (Pulse_Typing_Env.push_binding g' hyp + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_eq2 Pulse_Syntax_Pure.u0 + Pulse_Typing.tm_bool b Pulse_Typing.tm_true)) e1 + c1 d_e12 g1 in + let d_e14 = d_e13 in + let d_e21 = d_e2 in + let d_e22 = d_e21 in + let d_e23 = + st_typing_weakening g + (Pulse_Typing_Env.push_binding g' hyp + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_eq2 Pulse_Syntax_Pure.u0 + Pulse_Typing.tm_bool b Pulse_Typing.tm_false)) e2 + c1 d_e22 g1 in + let d_e24 = d_e23 in + Pulse_Typing.T_If + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), b, e1, e2, c1, + uc, hyp, (), d_e14, d_e24, ()) + | Pulse_Typing.T_Match + (uu___, sc_u, sc_ty, sc, d_sc_ty, d_sc, c1, brs, d_brs, + d_pats_complete) + -> Prims.magic () + | Pulse_Typing.T_Frame (uu___, e, c1, frame, uu___1, d_e) -> + Pulse_Typing.T_Frame + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), e, c1, frame, + (), (st_typing_weakening g g' e c1 d_e g1)) + | Pulse_Typing.T_Equiv (uu___, e, c1, c', d_e, d_eq) -> + Pulse_Typing.T_Equiv + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), e, c1, c', + (st_typing_weakening g g' e c1 d_e g1), + (st_equiv_weakening g g' c1 c' d_eq g1)) + | Pulse_Typing.T_IntroPure (uu___, p, uu___1, token) -> + Pulse_Typing.T_IntroPure + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), p, (), + (prop_validity_token_weakening uu___ p token + (Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'))) + | Pulse_Typing.T_ElimExists + (uu___, u, t1, p, x, uu___1, uu___2) -> + Pulse_Typing.T_ElimExists + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), u, t1, p, x, + (), ()) + | Pulse_Typing.T_IntroExists + (uu___, u, b, p, e, uu___1, uu___2, uu___3) -> + Pulse_Typing.T_IntroExists + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), u, b, p, e, (), + (), ()) + | Pulse_Typing.T_IntroExistsErased + (uu___, u, b, p, e, uu___1, uu___2, uu___3) -> + Pulse_Typing.T_IntroExistsErased + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), u, b, p, e, (), + (), ()) + | Pulse_Typing.T_While + (uu___, inv, cond, body, uu___1, cond_typing, body_typing) + -> + Pulse_Typing.T_While + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), inv, cond, + body, (), + (st_typing_weakening g g' cond + (Pulse_Typing.comp_while_cond + Pulse_Syntax_Base.ppname_default inv) cond_typing + g1), + (st_typing_weakening g g' body + (Pulse_Typing.comp_while_body + Pulse_Syntax_Base.ppname_default inv) body_typing + g1)) + | Pulse_Typing.T_Par + (uu___, eL, cL, eR, cR, x, cL_typing, cR_typing, eL_typing, + eR_typing) + -> + Pulse_Typing.T_Par + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), eL, cL, eR, cR, + x, + (comp_typing_weakening g g' cL + (Pulse_Syntax_Base.comp_u cL) cL_typing g1), + (comp_typing_weakening g g' cR + (Pulse_Syntax_Base.comp_u cR) cR_typing g1), + (st_typing_weakening g g' eL cL eL_typing g1), + (st_typing_weakening g g' eR cR eR_typing g1)) + | Pulse_Typing.T_WithLocal + (uu___, init, body, init_t, c1, x, uu___1, uu___2, d_c, + d_body) + -> + let d_body1 = d_body in + let d_body2 = d_body1 in + let d_body3 = + st_typing_weakening g + (Pulse_Typing_Env.push_binding g' x + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_ref init_t)) + (Pulse_Syntax_Naming.open_st_term_nv body + (Pulse_Syntax_Base.v_as_nv x)) + (Pulse_Typing.comp_withlocal_body x init_t init c1) + d_body2 g1 in + let d_body4 = d_body3 in + Pulse_Typing.T_WithLocal + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), init, body, + init_t, c1, x, (), (), + (comp_typing_weakening g g' c1 + (Pulse_Syntax_Base.comp_u c1) d_c g1), d_body4) + | Pulse_Typing.T_Rewrite (uu___, p, q, uu___1, uu___2) -> + Pulse_Typing.T_Rewrite + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), p, q, (), ()) + | Pulse_Typing.T_Admit (uu___, s, c1, d_s) -> + Pulse_Typing.T_Admit + ((Pulse_Typing_Env.push_env + (Pulse_Typing_Env.push_env g g1) g'), s, c1, + (st_comp_typing_weakening g g' s d_s g1)) +let (nt : + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.term -> Pulse_Syntax_Naming.subst_elt Prims.list) + = fun x -> fun t -> [Pulse_Syntax_Naming.NT (x, t)] +let (non_informative_t_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.universe -> + Pulse_Syntax_Base.term -> + (unit, unit, unit) Pulse_Typing.non_informative_t -> + (unit, unit, unit) Pulse_Typing.non_informative_t) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun u -> + fun t1 -> + fun d -> + let ss = nt x e in + let uu___ = d in + match uu___ with + | Prims.Mkdtuple2 (w, uu___1) -> + Prims.Mkdtuple2 + ((Pulse_Syntax_Naming.subst_term w ss), ()) +let (non_informative_c_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.comp -> + (unit, unit) Pulse_Typing.non_informative_c -> + (unit, unit) Pulse_Typing.non_informative_c) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun c -> + fun d -> + non_informative_t_subst g x t g' e () + (Pulse_Syntax_Base.comp_u c) + (Pulse_Syntax_Base.comp_res c) d +let (lift_comp_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit) Pulse_Typing.lift_comp -> + (unit, unit, unit) Pulse_Typing.lift_comp) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun c1 -> + fun c2 -> + fun d -> + let ss = nt x e in + match d with + | Pulse_Typing.Lift_STAtomic_ST (uu___, c) -> + Pulse_Typing.Lift_STAtomic_ST + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_comp c ss)) + | Pulse_Typing.Lift_STGhost_STAtomic + (uu___, c, d_non_informative) -> + Pulse_Typing.Lift_STGhost_STAtomic + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_comp c ss), + (non_informative_c_subst g x t g' e () c + d_non_informative)) +let (bind_comp_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp + -> + (unit, unit, unit, unit, unit) Pulse_Typing.bind_comp) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun y -> + fun c1 -> + fun c2 -> + fun c3 -> + fun d -> + let ss = nt x e in + match d with + | Pulse_Typing.Bind_comp + (uu___, y1, c11, c21, uu___1, z, uu___2) -> + Pulse_Typing.Bind_comp + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + y1, (Pulse_Syntax_Naming.subst_comp c11 ss), + (Pulse_Syntax_Naming.subst_comp c21 ss), (), + z, ()) + | Pulse_Typing.Bind_comp_ghost_l + (uu___, y1, c11, c21, d_non_informative, uu___1, + z, uu___2) + -> + Pulse_Typing.Bind_comp_ghost_l + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + y1, (Pulse_Syntax_Naming.subst_comp c11 ss), + (Pulse_Syntax_Naming.subst_comp c21 ss), + (non_informative_c_subst g x t g' e () c11 + d_non_informative), (), z, ()) + | Pulse_Typing.Bind_comp_ghost_r + (uu___, y1, c11, c21, d_non_informative, uu___1, + z, uu___2) + -> + Pulse_Typing.Bind_comp_ghost_r + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + y1, (Pulse_Syntax_Naming.subst_comp c11 ss), + (Pulse_Syntax_Naming.subst_comp c21 ss), + (non_informative_c_subst g x t g' e () c21 + d_non_informative), (), z, ()) +let (st_equiv_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.comp -> + (unit, unit, unit) Pulse_Typing.st_equiv -> + (unit, unit, unit) Pulse_Typing.st_equiv) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun c1 -> + fun c2 -> + fun d -> + match d with + | Pulse_Typing.ST_VPropEquiv + (uu___, c11, c21, y, uu___1, uu___2, uu___3, uu___4, + uu___5) + -> + Pulse_Typing.ST_VPropEquiv + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_comp c11 (nt x e)), + (Pulse_Syntax_Naming.subst_comp c21 (nt x e)), y, + (), (), (), (), ()) +let (st_comp_typing_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.st_comp -> + (unit, unit) Pulse_Typing.st_comp_typing -> + (unit, unit) Pulse_Typing.st_comp_typing) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun s -> + fun d -> + match d with + | Pulse_Typing.STC (uu___, s1, y, uu___1, uu___2, uu___3) + -> + Pulse_Typing.STC + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_comp s1 (nt x e)), y, + (), (), ()) +let (comp_typing_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.comp -> + Pulse_Syntax_Base.universe -> + (unit, unit, unit) Pulse_Typing.comp_typing -> + (unit, unit, unit) Pulse_Typing.comp_typing) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun c -> + fun u -> + fun d -> + match d with + | Pulse_Typing.CT_Tot (uu___, t1, u1, uu___1) -> + Pulse_Typing.CT_Tot + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term t1 (nt x e)), u1, + ()) + | Pulse_Typing.CT_ST (uu___, s, d_s) -> + Pulse_Typing.CT_ST + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), + (st_comp_typing_subst g x t g' e () s d_s)) + | Pulse_Typing.CT_STAtomic + (uu___, inames, s, uu___1, d_s) -> + Pulse_Typing.CT_STAtomic + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + inames, + (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), + (), (st_comp_typing_subst g x t g' e () s d_s)) + | Pulse_Typing.CT_STGhost (uu___, inames, s, uu___1, d_s) + -> + Pulse_Typing.CT_STGhost + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + inames, + (Pulse_Syntax_Naming.subst_st_comp s (nt x e)), + (), (st_comp_typing_subst g x t g' e () s d_s)) +let coerce_eq : 'a 'b . 'a -> unit -> 'b = + fun uu___1 -> fun uu___ -> (fun x -> fun uu___ -> Obj.magic x) uu___1 uu___ +let rec (st_typing_subst : + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.var -> + Pulse_Syntax_Base.typ -> + Pulse_Typing_Env.env -> + Pulse_Syntax_Base.term -> + unit -> + Pulse_Syntax_Base.st_term -> + Pulse_Syntax_Base.comp_st -> + (unit, unit, unit) Pulse_Typing.st_typing -> + (unit, unit, unit) Pulse_Typing.st_typing) + = + fun g -> + fun x -> + fun t -> + fun g' -> + fun e -> + fun e_typing -> + fun e1 -> + fun c1 -> + fun e1_typing -> + let ss = nt x e in + match e1_typing with + | Pulse_Typing.T_Abs + (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, + uu___6, uu___7, uu___8) + -> Prims.magic () + | Pulse_Typing.T_STApp + (uu___, head, ty, q, res, arg, uu___1, uu___2) -> + Pulse_Typing.T_STApp + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term head ss), + (Pulse_Syntax_Naming.subst_term ty ss), q, + (Pulse_Syntax_Naming.subst_comp res ss), + (Pulse_Syntax_Naming.subst_term arg ss), (), ()) + | Pulse_Typing.T_Return + (uu___, c, use_eq, u, t1, e2, post, x1, uu___1, + uu___2, uu___3) + -> + Pulse_Typing.T_Return + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), c, + use_eq, u, + (Pulse_Syntax_Naming.subst_term t1 ss), + (Pulse_Syntax_Naming.subst_term e2 ss), + (Pulse_Syntax_Naming.subst_term post ss), x1, (), + (), ()) + | Pulse_Typing.T_Lift (uu___, e2, c11, c2, d_e, d_lift) + -> + Pulse_Typing.T_Lift + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_comp c11 ss), + (Pulse_Syntax_Naming.subst_comp c2 ss), + (st_typing_subst g x t g' e () e2 c11 d_e), + (lift_comp_subst g x t g' e () c11 c2 d_lift)) + | Pulse_Typing.T_Bind + (uu___, e11, e2, c11, c2, b, y, c, d_e1, uu___1, + d_e2, d_bc) + -> + Pulse_Typing.T_Bind + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_term e11 ss), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_comp c11 ss), + (Pulse_Syntax_Naming.subst_comp c2 ss), + (Pulse_Syntax_Naming.subst_binder b ss), y, + (Pulse_Syntax_Naming.subst_comp c ss), + (st_typing_subst g x t g' e () e11 c11 d_e1), (), + (coerce_eq + (st_typing_subst g x t + (Pulse_Typing_Env.push_binding g' y + Pulse_Syntax_Base.ppname_default + (Pulse_Syntax_Base.comp_res c11)) e () + (Pulse_Syntax_Naming.open_st_term_nv e2 + ((b.Pulse_Syntax_Base.binder_ppname), y)) + c2 d_e2) ()), + (bind_comp_subst g x t g' e () y c11 c2 c d_bc)) + | Pulse_Typing.T_TotBind + (uu___, e11, e2, t1, c2, y, uu___1, d_e2) -> + Pulse_Typing.T_TotBind + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term e11 ss), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_term t1 ss), + (Pulse_Syntax_Naming.subst_comp c2 ss), y, (), + (coerce_eq + (st_typing_subst g x t + (Pulse_Typing_Env.push_binding g' y + Pulse_Syntax_Base.ppname_default t1) e + () + (Pulse_Syntax_Naming.open_st_term_nv e2 + (Pulse_Syntax_Base.v_as_nv y)) c2 d_e2) + ())) + | Pulse_Typing.T_If + (uu___, b, e11, e2, c, uc, hyp, uu___1, d_e1, d_e2, + uu___2) + -> + Pulse_Typing.T_If + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term b ss), + (Pulse_Syntax_Naming.subst_st_term e11 ss), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_comp c ss), uc, hyp, + (), + (coerce_eq + (st_typing_subst g x t + (Pulse_Typing_Env.push_binding g' hyp + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_eq2 + Pulse_Syntax_Pure.u0 + Pulse_Typing.tm_bool b + Pulse_Typing.tm_true)) e () e11 c + d_e1) ()), + (coerce_eq + (st_typing_subst g x t + (Pulse_Typing_Env.push_binding g' hyp + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_eq2 + Pulse_Syntax_Pure.u0 + Pulse_Typing.tm_bool b + Pulse_Typing.tm_false)) e () e2 c + d_e2) ()), ()) + | Pulse_Typing.T_Match + (uu___, uu___1, uu___2, uu___3, uu___4, uu___5, + uu___6, uu___7, uu___8, uu___9) + -> Prims.magic () + | Pulse_Typing.T_Frame (uu___, e2, c, frame, uu___1, d_e) + -> + Pulse_Typing.T_Frame + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_comp c ss), + (Pulse_Syntax_Naming.subst_term frame ss), (), + (st_typing_subst g x t g' e () e2 c d_e)) + | Pulse_Typing.T_Equiv (uu___, e2, c, c', d_e, d_eq) -> + Pulse_Typing.T_Equiv + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_term e2 ss), + (Pulse_Syntax_Naming.subst_comp c ss), + (Pulse_Syntax_Naming.subst_comp c' ss), + (st_typing_subst g x t g' e () e2 c d_e), + (st_equiv_subst g x t g' e () c c' d_eq)) + | Pulse_Typing.T_IntroPure (uu___, p, uu___1, uu___2) -> + Pulse_Typing.T_IntroPure + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term p ss), (), + (Prims.magic ())) + | Pulse_Typing.T_ElimExists + (uu___, u, t1, p, y, uu___1, uu___2) -> + Pulse_Typing.T_ElimExists + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), u, + (Pulse_Syntax_Naming.subst_term t1 ss), + (Pulse_Syntax_Naming.subst_term p ss), y, (), ()) + | Pulse_Typing.T_IntroExists + (uu___, u, b, p, e2, uu___1, uu___2, uu___3) -> + Pulse_Typing.T_IntroExists + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), u, + (Pulse_Syntax_Naming.subst_binder b ss), + (Pulse_Syntax_Naming.subst_term p ss), + (Pulse_Syntax_Naming.subst_term e2 ss), (), (), + ()) + | Pulse_Typing.T_IntroExistsErased + (uu___, u, b, p, e2, uu___1, uu___2, uu___3) -> + Pulse_Typing.T_IntroExistsErased + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), u, + (Pulse_Syntax_Naming.subst_binder b ss), + (Pulse_Syntax_Naming.subst_term p ss), + (Pulse_Syntax_Naming.subst_term e2 ss), (), (), + ()) + | Pulse_Typing.T_While + (uu___, inv, cond, body, uu___1, cond_typing, + body_typing) + -> + Pulse_Typing.T_While + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term inv ss), + (Pulse_Syntax_Naming.subst_st_term cond ss), + (Pulse_Syntax_Naming.subst_st_term body ss), (), + (st_typing_subst g x t g' e () cond + (Pulse_Typing.comp_while_cond + Pulse_Syntax_Base.ppname_default inv) + cond_typing), + (st_typing_subst g x t g' e () body + (Pulse_Typing.comp_while_body + Pulse_Syntax_Base.ppname_default inv) + body_typing)) + | Pulse_Typing.T_Par + (uu___, eL, cL, eR, cR, y, d_cL, d_cR, d_eL, d_eR) -> + Pulse_Typing.T_Par + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_term eL ss), + (Pulse_Syntax_Naming.subst_comp cL ss), + (Pulse_Syntax_Naming.subst_st_term eR ss), + (Pulse_Syntax_Naming.subst_comp cR ss), y, + (comp_typing_subst g x t g' e () cL + (Pulse_Syntax_Base.comp_u cL) d_cL), + (comp_typing_subst g x t g' e () cR + (Pulse_Syntax_Base.comp_u cR) d_cR), + (st_typing_subst g x t g' e () eL cL d_eL), + (st_typing_subst g x t g' e () eR cR d_eR)) + | Pulse_Typing.T_WithLocal + (uu___, init, body, init_t, c, y, uu___1, uu___2, + d_c, d_body) + -> + Pulse_Typing.T_WithLocal + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term init ss), + (Pulse_Syntax_Naming.subst_st_term body ss), + (Pulse_Syntax_Naming.subst_term init_t ss), + (Pulse_Syntax_Naming.subst_comp c ss), y, (), (), + (comp_typing_subst g x t g' e () c + (Pulse_Syntax_Base.comp_u c) d_c), + (coerce_eq + (st_typing_subst g x t + (Pulse_Typing_Env.push_binding g' y + Pulse_Syntax_Base.ppname_default + (Pulse_Typing.mk_ref init_t)) e () + (Pulse_Syntax_Naming.open_st_term_nv body + (Pulse_Syntax_Base.v_as_nv y)) + (Pulse_Typing.comp_withlocal_body y init_t + init c) d_body) ())) + | Pulse_Typing.T_Rewrite (uu___, p, q, uu___1, uu___2) -> + Pulse_Typing.T_Rewrite + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_term p ss), + (Pulse_Syntax_Naming.subst_term q ss), (), ()) + | Pulse_Typing.T_Admit (uu___, s, c, d_s) -> + Pulse_Typing.T_Admit + ((Pulse_Typing_Env.push_env g + (Pulse_Typing_Env.subst_env g' (nt x e))), + (Pulse_Syntax_Naming.subst_st_comp s ss), c, + (st_comp_typing_subst g x t g' e () s d_s)) \ No newline at end of file diff --git a/src/proofs/steelc/Steel.ST.C.Types.Struct.fst b/src/proofs/steelc/Steel.ST.C.Types.Struct.fst index 9c537bc13..99155deb7 100644 --- a/src/proofs/steelc/Steel.ST.C.Types.Struct.fst +++ b/src/proofs/steelc/Steel.ST.C.Types.Struct.fst @@ -67,61 +67,151 @@ let struct_get_field_uninitialized tn n fields field = () +let has_struct_field_spec + (#tf: Type0) + (fields: nonempty_field_description_t tf) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') + (r1: ref ((fd_gen_of_nonempty_fd fields).fd_typedef field)) +: Tot prop += t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + r' == coerce_eq () r1 + +[@@__reduce__] +let has_struct_field9 + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') += exists_ (fun (r1: ref ((fd_gen_of_nonempty_fd fields).fd_typedef field)) -> + has_struct_field1 r field r1 `star` + pure (has_struct_field_spec fields field r' r1) + ) + let has_struct_field r field r' -= has_struct_field1 r field r' += has_struct_field9 r field r' + +let intro_has_struct_field + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') + (r1: ref ((fd_gen_of_nonempty_fd fields).fd_typedef field)) +: STGhost unit opened + (has_struct_field1 r field r1) + (fun _ -> has_struct_field r field r') + (has_struct_field_spec fields field r' r1) + (fun _ -> True) += noop (); + rewrite (has_struct_field9 r field r') (has_struct_field r field r') + +let elim_has_struct_field + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (struct0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhost (Ghost.erased (ref ((fd_gen_of_nonempty_fd fields).fd_typedef field))) opened + (has_struct_field r field r') + (fun r1 -> has_struct_field1 r field r1) + True + (fun r1 -> has_struct_field_spec fields field r' r1) += rewrite (has_struct_field r field r') (has_struct_field9 r field r'); + let _ = gen_elim () in + vpattern_replace_erased (has_struct_field1 r field) + +let has_struct_field_prop + r field r' += let r1 = elim_has_struct_field r field r' in + intro_has_struct_field r field r' r1 let has_struct_field_dup #opened #tn #tf #n #fields r field r' -= let r'2 : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r' in - has_struct_field_dup' r field r'2 += let r'2 = elim_has_struct_field r field r' in + has_struct_field_dup' r field r'2; + intro_has_struct_field r field r' r'2; + intro_has_struct_field r field r' r'2 let has_struct_field_inj #_ #tn #tf #n #fields r field r1 r2 -= let r1' : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r1 in - let r2' : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r2 in - has_struct_field_inj' r field r1' r2' += let r1' = elim_has_struct_field r field r1 in + let r2' = elim_has_struct_field r field r2 in + has_struct_field_inj' r field r1' r2'; + intro_has_struct_field r field r1 r1'; + intro_has_struct_field r field r2 r2'; + rewrite (ref_equiv r1' r2') (ref_equiv r1 r2) let has_struct_field_equiv_from #_ #tn #tf #n #fields r1 field r' r2 -= let r'_ : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r' in - has_struct_field_equiv_from' r1 field r'_ r2 += let r'_ = elim_has_struct_field r1 field r' in + has_struct_field_equiv_from' r1 field r'_ r2; + intro_has_struct_field r2 field r' r'_ let has_struct_field_equiv_to #_ #tn #tf #n #fields r field r1 r2 -= let r1' : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r1 in += let r1' = elim_has_struct_field r field r1 in let r2' : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r2 in - has_struct_field_equiv_to' r field r1' r2' + rewrite (ref_equiv r1 r2) (ref_equiv r1' r2'); + has_struct_field_equiv_to' r field r1' r2'; + rewrite (ref_equiv r1' r2') (ref_equiv r1 r2); + intro_has_struct_field r field r2 r2' let ghost_struct_field_focus - #_ #tn #tf #n #fields r field r' -= let r'_ : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r' in - ghost_struct_field_focus' r field r'_ + #_ #tn #tf #n #fields #v r field #t' #td' r' += let r'_ = elim_has_struct_field r field r' in + let sq : squash ( + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + ) = () in + ghost_struct_field_focus' r field r'_; + rewrite (pts_to r'_ _) (pts_to r' (Ghost.hide (coerce_eq () (struct_get_field v field)))); + intro_has_struct_field r field r' r'_; + sq let ghost_struct_field #_ #tn #tf #n #fields #v r field = let r' = ghost_struct_field' r field in let r'2 : Ghost.erased (ref (fields.fd_typedef field)) = coerce_eq () r' in rewrite (pts_to r' _) (pts_to r'2 (struct_get_field v field)); - rewrite (has_struct_field1 r field r') (has_struct_field r field r'2); + intro_has_struct_field r field r'2 r'; r'2 let struct_field0 t' #_ #_ #v r field td' = let r1' = struct_field' r field in - let r' : ref td' = r1' in + let r' : ref td' = coerce_eq () r1' in rewrite (pts_to r1' _) (pts_to r' (struct_get_field v field)); - rewrite (has_struct_field1 _ _ _) (has_struct_field r field r'); + intro_has_struct_field r field r' r1'; return r' let unstruct_field - #_ #tn #tf #n #fields #v r field #v' r' -= let r'_ : ref ((fd_gen_of_nonempty_fd fields).fd_typedef field) = coerce_eq () r' in + #_ #tn #tf #n #fields #v r field #_ #_ #v' r' += let r'_ = elim_has_struct_field r field r' in let v'_ : Ghost.erased ((fd_gen_of_nonempty_fd fields).fd_type field) = coerce_eq () v' in - rewrite (has_struct_field r field r') (has_struct_field1 r field r'_); rewrite (pts_to r' v') (pts_to r'_ v'_); unstruct_field' r field r'_; - rewrite (has_struct_field1 r field r'_) (has_struct_field r field r') + intro_has_struct_field r field r' r'_; + _ let fractionable_struct _ = () let mk_fraction_struct _ _ _ = () diff --git a/src/proofs/steelc/Steel.ST.C.Types.Union.fst b/src/proofs/steelc/Steel.ST.C.Types.Union.fst index c8190e696..29d26ecc6 100644 --- a/src/proofs/steelc/Steel.ST.C.Types.Union.fst +++ b/src/proofs/steelc/Steel.ST.C.Types.Union.fst @@ -380,40 +380,225 @@ let has_union_field05 : Tot vprop = has_focus_ref r (U.union_field (union_field_pcm fields) (Some field)) r' +let has_union_field' + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (r': ref (fields.fd_typedef field)) +: Tot vprop += has_union_field0 r field r' + +let has_union_field1_prop + (#tf: Type0) + (fields: field_description_t tf) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') + (r1: ref (fields.fd_typedef field)) +: Tot prop += t' == fields.fd_type field /\ + td' == fields.fd_typedef field /\ + r1 == coerce_eq () r' + +[@@__reduce__] +let has_union_field1 + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') +: Tot vprop += exists_ (fun (r1: ref (fields.fd_typedef field)) -> + has_union_field' r field r1 `star` + pure (has_union_field1_prop fields field r' r1) + ) + let has_union_field r field r' -= has_union_field0 r field r' += has_union_field1 r field r' -let has_union_field_dup +let intro_has_union_field + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') + (r1: ref (fields.fd_typedef field)) +: STGhost unit opened + (has_union_field' r field r1) + (fun _ -> has_union_field r field r') + (has_union_field1_prop fields field r' r1) + (fun _ -> True) += noop (); + rewrite (has_union_field1 r field r') (has_union_field r field r') + +let elim_has_union_field + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#t': Type0) + (#td': typedef t') + (r': ref td') +: STGhost (Ghost.erased (ref (fields.fd_typedef field))) opened + (has_union_field r field r') + (fun r1 -> has_union_field' r field r1) + True + (fun r1 -> has_union_field1_prop fields field r' r1) += rewrite (has_union_field r field r') (has_union_field1 r field r'); + let _ = gen_elim () in + vpattern_replace_erased (has_union_field' r field) + +let has_union_field_prop + r field r' += let r1 = elim_has_union_field r field r' in + intro_has_union_field r field r' _ + +val has_union_field_dup' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (r': ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r field r') + (fun _ -> has_union_field' r field r' `star` has_union_field' r field r') + +let has_union_field_dup' r field r' -= rewrite (has_union_field r field r') (has_union_field05 r field r'); += rewrite (has_union_field' r field r') (has_union_field05 r field r'); has_focus_ref_dup r _ r'; - rewrite (has_union_field05 r field r') (has_union_field r field r'); - rewrite (has_union_field05 r field r') (has_union_field r field r') + rewrite (has_union_field05 r field r') (has_union_field' r field r'); + rewrite (has_union_field05 r field r') (has_union_field' r field r') -let has_union_field_inj +let has_union_field_dup + r field r' += let r1 = elim_has_union_field r field r' in + has_union_field_dup' r field r1; + intro_has_union_field r field r' r1; + intro_has_union_field r field r' r1 + +val has_union_field_inj' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (r1 r2: ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r field r1 `star` has_union_field' r field r2) + (fun _ -> has_union_field' r field r1 `star` has_union_field' r field r2 `star` ref_equiv r1 r2) + +let has_union_field_inj' #_ #tn #_ #n r field r1 r2 -= rewrite (has_union_field r field r1) (has_union_field05 r field r1); - rewrite (has_union_field r field r2) (has_union_field05 r field r2); += rewrite (has_union_field' r field r1) (has_union_field05 r field r1); + rewrite (has_union_field' r field r2) (has_union_field05 r field r2); has_focus_ref_inj r _ r1 r2; - rewrite (has_union_field05 r field r1) (has_union_field r field r1); - rewrite (has_union_field05 r field r2) (has_union_field r field r2) + rewrite (has_union_field05 r field r1) (has_union_field' r field r1); + rewrite (has_union_field05 r field r2) (has_union_field' r field r2) -let has_union_field_equiv_from +let has_union_field_inj + #_ #tn #_ #n r field #t1 #td1 r1 #t2 #td2 r2 += let r1' = elim_has_union_field r field r1 in + let r2' = elim_has_union_field r field r2 in + has_union_field_inj' r field r1' r2'; + let sq : squash (t1 == t2 /\ td1 == td2) = () in + intro_has_union_field r field r1 r1'; + intro_has_union_field r field r2 r2'; + rewrite (ref_equiv r1' r2') (ref_equiv r1 (coerce_eq () r2)); + sq + +val has_union_field_equiv_from' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r1 r2: ref (union0 tn n fields)) + (field: field_t fields) + (r': ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r1 field r' `star` ref_equiv r1 r2) + (fun _ -> has_union_field' r2 field r' `star` ref_equiv r1 r2) + +let has_union_field_equiv_from' r1 r2 field r' -= rewrite (has_union_field r1 field r') (has_union_field05 r1 field r'); += rewrite (has_union_field' r1 field r') (has_union_field05 r1 field r'); has_focus_ref_equiv_from r1 _ r' r2; - rewrite (has_union_field05 r2 field r') (has_union_field r2 field r') + rewrite (has_union_field05 r2 field r') (has_union_field' r2 field r') -let has_union_field_equiv_to +let has_union_field_equiv_from + r1 r2 field r' += let r3 = elim_has_union_field r1 field r' in + has_union_field_equiv_from' r1 r2 field r3; + intro_has_union_field r2 field r' r3 + +val has_union_field_equiv_to' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: nonempty_field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (r1 r2: ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r field r1 `star` ref_equiv r1 r2) + (fun _ -> has_union_field' r field r2 `star` ref_equiv r1 r2) + +let has_union_field_equiv_to' r field r1' r2' -= rewrite (has_union_field r field r1') (has_union_field05 r field r1'); += rewrite (has_union_field' r field r1') (has_union_field05 r field r1'); has_focus_ref_equiv_to r _ r1' r2'; - rewrite (has_union_field05 r field r2') (has_union_field r field r2') + rewrite (has_union_field05 r field r2') (has_union_field' r field r2') -let ghost_union_field_focus +let has_union_field_equiv_to + #_ #_ #_ #_ #fields r field r1' r2' += let r1 = elim_has_union_field r field r1' in + let r2 : ref (fields.fd_typedef field) = coerce_eq () r2' in + rewrite (ref_equiv r1' r2') (ref_equiv r1 r2); + has_union_field_equiv_to' r field r1 r2; + rewrite (ref_equiv r1 r2) (ref_equiv r1' r2'); + intro_has_union_field r field r2' r2 + +val ghost_union_field_focus' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (#v: Ghost.erased (union_t0 tn n fields)) + (r: ref (union0 tn n fields)) + (field: field_t fields {union_get_case v == Some field}) + (r': ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r field r' `star` pts_to r v) + (fun _ -> has_union_field' r field r' `star` pts_to r' (Ghost.hide (union_get_field v field))) + +let ghost_union_field_focus' #_ #tn #_ #n #fields #v r field r' -= rewrite (has_union_field r field r') (has_union_field0 r field r'); += rewrite (has_union_field' r field r') (has_union_field0 r field r'); let _ = gen_elim () in let w = vpattern_replace (HR.pts_to r _) in let w' = vpattern_replace (HR.pts_to r' _) in @@ -428,13 +613,44 @@ let ghost_union_field_focus hr_share r'; // pts_to_intro_rewrite r' rr' _ ; pts_to_intro_rewrite r' _ _ ; - rewrite (has_union_field0 r field r') (has_union_field r field r') + rewrite (has_union_field0 r field r') (has_union_field' r field r') -let ghost_union_field +let ghost_union_field_focus + #_ #tn #_ #n #fields #v r field #t' #td' r' += let r1 = elim_has_union_field r field r' in + let sq : squash ( + t' == fields.fd_type field /\ + td' == fields.fd_typedef field + ) = () in + ghost_union_field_focus' r field r1; + rewrite (pts_to r1 _) (pts_to r' (Ghost.hide (coerce_eq () (union_get_field v field)))); + intro_has_union_field r field r' r1; + sq + +val ghost_union_field' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (#v: Ghost.erased (union_t0 tn n fields)) + (r: ref (union0 tn n fields)) + (field: field_t fields {union_get_case v == Some field}) +: STGhostT (Ghost.erased (ref (fields.fd_typedef field))) opened + (pts_to r v) + (fun r' -> has_union_field' r field r' `star` pts_to r' (union_get_field v field)) + +let ghost_union_field' #_ #tn #_ #n #fields #v r field = let r' = ghost_focus_ref r (fields.fd_typedef field) (U.union_field (union_field_pcm fields) (Some field)) in - rewrite (has_union_field05 r field r') (has_union_field r field r'); - ghost_union_field_focus r field r'; + rewrite (has_union_field05 r field r') (has_union_field' r field r'); + ghost_union_field_focus' r field r'; + r' + +let ghost_union_field + #_ #tn #_ #n #fields #v r field += let r' = ghost_union_field' r field in + intro_has_union_field r field r' r'; r' [@@noextract_to "krml"] // primitive @@ -448,27 +664,41 @@ let union_field' (field: field_t fields {union_get_case v == Some field}) : STT (ref (fields.fd_typedef field)) (pts_to r v) - (fun r' -> has_union_field r field r' `star` pts_to r' (union_get_field v field)) + (fun r' -> has_union_field' r field r' `star` pts_to r' (union_get_field v field)) = let r' = focus_ref r (fields.fd_typedef field) (U.union_field (union_field_pcm fields) (Some field)) in - rewrite (has_union_field05 r field r') (has_union_field r field r'); - ghost_union_field_focus r field r'; + rewrite (has_union_field05 r field r') (has_union_field' r field r'); + ghost_union_field_focus' r field r'; return r' let union_field0 t' r field td' = let r' = union_field' r field in - let res : ref td' = r' in + let res : ref td' = coerce_eq () r' in rewrite (pts_to r' _) (pts_to res _); - rewrite (has_union_field r field _) (has_union_field r field res); + intro_has_union_field r field res r'; return res +val ununion_field' + (#opened: _) + (#tn: Type0) + (#tf: Type0) + (#n: string) + (#fields: field_description_t tf) + (r: ref (union0 tn n fields)) + (field: field_t fields) + (#v': Ghost.erased (fields.fd_type field)) + (r': ref (fields.fd_typedef field)) +: STGhostT unit opened + (has_union_field' r field r' `star` pts_to r' v') + (fun _ -> has_union_field' r field r' `star` pts_to r (union_set_field tn n fields field (Ghost.reveal v'))) + #push-options "--z3rlimit 16" #restart-solver -let ununion_field +let ununion_field' #_ #tn #_ #n #fields r field #v' r' -= rewrite (has_union_field r field r') (has_union_field0 r field r'); += rewrite (has_union_field' r field r') (has_union_field0 r field r'); let _ = gen_elim () in let w = vpattern_replace (HR.pts_to r _) in let w' = vpattern_replace (HR.pts_to r' _) in @@ -479,11 +709,20 @@ let ununion_field let rr' = get_ref r' in let x = r_unfocus rr' rr (coerce_eq () (U.union_field (union_field_pcm fields) (Some field))) _ in hr_share r; - rewrite (has_union_field0 r field r') (has_union_field r field r'); + rewrite (has_union_field0 r field r') (has_union_field' r field r'); pts_to_intro_rewrite r rr #x _ #pop-options +let ununion_field + #_ #tn #_ #n #fields r field #_ #_ #v' r' += let r1 = elim_has_union_field r field r' in + let v1 : Ghost.erased (fields.fd_type field) = Ghost.hide (coerce_eq () (Ghost.reveal v')) in + rewrite (pts_to r' v') (pts_to r1 v1); + ununion_field' r field r1; + intro_has_union_field r field r' r1; + _ + [@@noextract_to "krml"] // primitive let union_switch_field' (#tn: Type0) @@ -495,7 +734,7 @@ let union_switch_field' (field: field_t fields) : ST (ref (fields.fd_typedef field)) (pts_to r v) - (fun r' -> has_union_field r field r' `star` pts_to r' (uninitialized (fields.fd_typedef field))) + (fun r' -> has_union_field' r field r' `star` pts_to r' (uninitialized (fields.fd_typedef field))) (full (union0 tn n fields) v) (fun _ -> True) = rewrite (pts_to r v) (pts_to0 r v); @@ -510,32 +749,10 @@ let union_switch_field' rewrite (pts_to r' _) (pts_to r' (uninitialized (fields.fd_typedef field))); return r' -[@@noextract_to "krml"] // primitive -let union_switch_field0' - (#tn: Type0) - (#tf: Type0) - (t': Type0) - (#n: string) - (#fields: field_description_t tf) - (#v: Ghost.erased (union_t0 tn n fields)) - (r: ref (union0 tn n fields)) - (field: field_t fields) - (td': typedef t') - (sq: squash ( - t' == fields.fd_type field /\ - td' == fields.fd_typedef field - )) -: ST (ref td') // need to write the pcm carrier value, so this cannot be Ghost or Atomic - (pts_to r v) - (fun r' -> has_union_field r field (coerce_eq () r') `star` pts_to r' (Ghost.hide (coerce_eq () (uninitialized (fields.fd_typedef field))))) - (full (union0 tn n fields) v) - (fun _ -> True) -= let r' = union_switch_field' #tn #tf #n #fields #v r field in - let res : ref td' = r' in +let union_switch_field0 + t' #_ #fields r field td' += let r' = union_switch_field' r field in + let res : ref td' = coerce_eq () r' in rewrite (pts_to r' _) (pts_to res (Ghost.hide (coerce_eq () (uninitialized (fields.fd_typedef field))))); - rewrite (has_union_field r field _) (has_union_field r field (coerce_eq () res)); + intro_has_union_field r field res r'; return res - -let union_switch_field0 - t' r field td' -= union_switch_field0' t' r field td' ()