diff options
| author | Théo Zimmermann | 2016-10-27 14:14:50 +0200 |
|---|---|---|
| committer | Matthieu Sozeau | 2016-11-03 16:26:40 +0100 |
| commit | 919545d39c77a9168e70141e78d2c9589dad7c4e (patch) | |
| tree | 9bc2eda4f2f8c7bd1eceb0649898ad2ffc71b4e5 /tactics | |
| parent | f6916774eea2ecc1262377cb14c2d494a0486358 (diff) | |
Internal API change to typeclasses eauto.
This commit makes the traversing strategy of typeclasses
eauto an optional argument of the function that implements
it.
This change should be non-breaking.
Diffstat (limited to 'tactics')
| -rw-r--r-- | tactics/class_tactics.ml | 9 | ||||
| -rw-r--r-- | tactics/class_tactics.mli | 3 |
2 files changed, 10 insertions, 2 deletions
diff --git a/tactics/class_tactics.ml b/tactics/class_tactics.ml index fe12b54a13..5d5511d78f 100644 --- a/tactics/class_tactics.ml +++ b/tactics/class_tactics.ml @@ -1288,11 +1288,16 @@ module Search = struct tclCASE (with_shelf tac) >>= casefn let eauto_tac ?(st=full_transparent_state) ?(unique=false) - ~only_classes ~depth ~dep hints = + ~only_classes ?dfs ~depth ~dep hints = let open Proofview in let tac = let search = search_tac ~st only_classes dep hints in - if get_typeclasses_iterative_deepening () then + let bfs = + match dfs with + | None -> get_typeclasses_iterative_deepening () + | Some v -> v + in + if bfs then match depth with | None -> fix_iterative search | Some l -> fix_iterative_limit l search diff --git a/tactics/class_tactics.mli b/tactics/class_tactics.mli index 21c5d2172b..1b2fa035bd 100644 --- a/tactics/class_tactics.mli +++ b/tactics/class_tactics.mli @@ -44,6 +44,9 @@ module Search : sig (** Should we force a unique solution *) only_classes:bool -> (** Should non-class goals be shelved and resolved at the end *) + ?dfs:bool -> + (** Is a traversing-strategy specified? + If yes, true means dfs, false means bfs, i.e iterative deepening *) depth:Int.t option -> (** Bounded or unbounded search *) dep:bool -> |
