| NCicMetaSubst.MetaSubstFailure _ as exn -> fail ~exn (lazy fname)
;;
+class type g_pstatus =
+ object
+ inherit NEstatus.g_status
+ method obj: NCic.obj
+ end
+
class pstatus =
fun (o: NCic.obj) ->
- object
+ object (self)
inherit NEstatus.status
val obj = o
method obj = obj
method set_obj o = {< obj = o >}
+ method set_pstatus : 'status. #g_pstatus as 'status -> 'self
+ = fun o -> (self#set_estatus o)#set_obj o#obj
end
type tactic_term = CicNotationPt.term Disambiguate.disambiguator_input
(* ============= move this elsewhere ====================*)
+class type ['stack] g_status =
+ object
+ inherit g_pstatus
+ method stack: 'stack
+ end
+
class ['stack] status =
fun (o: NCic.obj) (s: 'stack) ->
- object
+ object (self)
inherit (pstatus o)
val stack = s
method stack = stack
method set_stack s = {< stack = s >}
+ method set_status : 'status. 'stack #g_status as 'status -> 'self
+ = fun o -> (self#set_pstatus o)#set_stack o#stack
end
class type lowtac_status = [unit] status
exception Error of string lazy_t * exn option
val fail: ?exn:exn -> string lazy_t -> 'a
+class type g_pstatus =
+ object
+ inherit NEstatus.g_status
+ method obj: NCic.obj
+ end
+
class pstatus :
NCic.obj ->
object ('self)
inherit NEstatus.status
method obj: NCic.obj
method set_obj: NCic.obj -> 'self
+ method set_pstatus: #g_pstatus -> 'self
end
type tactic_term = CicNotationPt.term Disambiguate.disambiguator_input
val pp_status: #pstatus -> unit
+class type ['stack] g_status =
+ object
+ inherit g_pstatus
+ method stack: 'stack
+ end
+
class ['stack] status :
NCic.obj -> 'stack ->
object ('self)
inherit pstatus
method stack: 'stack
method set_stack: 'stack -> 'self
+ method set_status: 'stack #g_status -> 'self
end
class type lowtac_status = [unit] status
exception Gaveup of IntSet.t (* a sublist of unprovable conjunctive
atoms of the input goals *)
-exception Proved of #NTacStatus.tac_status
+exception Proved of NTacStatus.tac_status
(* let close_failures _ c = c;; *)
(* let prunable _ _ _ = false;; *)
(* warning: ctx is supposed to be already instantiated w.r.t subst *)
let index_local_equations eq_cache status =
let open_goals = head_goals status#stack in
- assert (List.length open_goals = 1);
+(* assert (List.length open_goals = 1); *)
let open_goal = List.hd open_goals in
let ngty = get_goalty status open_goal in
let ctx = ctx_of ngty in
(* backward aplications *)
let l1 = applicative_case depth signature status flags gty cache in
(* fast paramodulation *)
- let l2 =
+ let l2 = [] in
+(*
List.map
(fun s ->
incr candidate_no;
((!candidate_no,Ast.Ident("__paramod",None)),s))
(auto_eq_check cache.unit_eq status)
- (* states in l2 have have an set of subgoals: no point to sort them *)
in
+*)
+ (* states in l2 have have an set of subgoals: no point to sort them *)
l2 @ (sort_new_elems (l@l1)), cache
;;
;;
let auto_tac ~params:(_univ,flags) status =
+ let oldstatus = status in
+ let status = (status:> NTacStatus.tac_status) in
let goals = head_goals status#stack in
let status, facts = mk_th_cache status goals in
let unit_eq = index_local_equations status#eq_cache status in
| (g,t,k,f) :: rest -> (filter_open g,t,k,f):: rest
| _ -> assert false
in
- s#set_stack stack
+ let s = s#set_stack stack in
+ oldstatus#set_status s
in
let s = up_to depth depth in
print(lazy