equal
deleted
inserted
replaced
47 in |
47 in |
48 set_preplay_time l (false, time); |
48 set_preplay_time l (false, time); |
49 mk_step_lfs_gfs min_lfs min_gfs |
49 mk_step_lfs_gfs min_lfs min_gfs |
50 end) |
50 end) |
51 |
51 |
52 fun minimize_dependencies_and_remove_unrefed_steps |
52 fun minimize_dependencies_and_remove_unrefed_steps isar_try0 preplay_interface |
53 isar_minimize preplay_interface proof = |
53 proof = |
54 let |
54 let |
55 fun cons_to xs x = x :: xs |
55 fun cons_to xs x = x :: xs |
56 |
56 |
57 val add_lfs = fold (Ord_List.insert label_ord) |
57 val add_lfs = fold (Ord_List.insert label_ord) |
58 |
58 |
84 else |
84 else |
85 (refed, accu) |
85 (refed, accu) |
86 |
86 |
87 and do_refed_step step = |
87 and do_refed_step step = |
88 step |
88 step |
89 |> isar_minimize ? min_deps_of_step preplay_interface |
89 |> isar_try0 ? min_deps_of_step preplay_interface |
90 |> do_refed_step' |
90 |> do_refed_step' |
91 |
91 |
92 and do_refed_step' (Let _) = raise Fail "Sledgehammer_Minimize_Isar" |
92 and do_refed_step' (Let _) = raise Fail "Sledgehammer_Minimize_Isar" |
93 | do_refed_step' (Prove (qs, xs, l, t, subproofs, By ((lfs, gfs), m))) = |
93 | do_refed_step' (Prove (qs, xs, l, t, subproofs, By ((lfs, gfs), m))) = |
94 let |
94 let |
99 |>> add_lfs lfs |
99 |>> add_lfs lfs |
100 val step = Prove (qs, xs, l, t, subproofs, By ((lfs, gfs), m)) |
100 val step = Prove (qs, xs, l, t, subproofs, By ((lfs, gfs), m)) |
101 in |
101 in |
102 (refed, step) |
102 (refed, step) |
103 end |
103 end |
104 |
|
105 in |
104 in |
106 snd (do_proof proof) |
105 snd (do_proof proof) |
107 end |
106 end |
108 |
107 |
109 end |
108 end |