File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -150,7 +150,6 @@ end = struct
150150 let + tc = EcPhlSkip. t_skip tc in
151151 let + tc = EcLowGoal. t_intro_s `Fresh tc in
152152 let + tc = EcLowGoal. t_elim_and tc in
153-
154153 let e = EcEnv.LDecl. fresh_id (FApi. tc1_hyps tc) " e" in
155154
156155 let + tc = EcLowGoal. t_intros_i [e] tc in
@@ -173,10 +172,26 @@ end = struct
173172 in
174173
175174 let clean (tc : tcenv1 ) =
175+ let discharge_pre tc =
176+ let + tc =
177+ if Option. is_some side
178+ then EcLowGoal. t_intros_n 2 tc
179+ else EcLowGoal. t_intros_n 1 tc
180+ in
181+ let + tc = EcLowGoal. t_elim_and tc in
182+ let + tc = EcLowGoal. t_intro_s `Fresh tc in
183+ let + tc = EcLowGoal. t_elim_and tc in
184+ let + tc = EcLowGoal. t_intros_n ~clear: true 1 tc in
185+ let + tc = EcLowGoal. t_intro_s `Fresh tc in
186+
187+ t_id tc
188+ in
189+
176190 let pre = oget (EcLowPhlGoal. get_pre (FApi. tc1_goal tc)) in
177191 let post = oget (EcLowPhlGoal. get_post (FApi. tc1_goal tc)) in
178192 let eq, _, pre = destr_and3 pre in
179193 let tc = EcPhlConseq. t_conseq (f_and eq pre) post tc in
194+ let tc = FApi. t_first discharge_pre tc in
180195
181196 FApi. t_onall
182197 (EcLowGoal. t_clears names)
You can’t perform that action at this time.
0 commit comments