aboutsummaryrefslogtreecommitdiff
path: root/tactics
diff options
context:
space:
mode:
authorPierre-Marie Pédrot2020-08-24 16:39:19 +0200
committerPierre-Marie Pédrot2020-09-18 11:43:45 +0200
commita00a51f312720d1cfbc138664f6ea50b2d6fb3c6 (patch)
treeda1f92986143536dd9ca92ad9eb656f769f0cf9d /tactics
parentfdacb149ddb874acd5e5d7943d93bfab1955f4a1 (diff)
Remove dead code in dnets.
The boolean assumedly used to cut recursion was always set to true, since its introduction in 64ac193.
Diffstat (limited to 'tactics')
-rw-r--r--tactics/dn.ml10
1 files changed, 4 insertions, 6 deletions
diff --git a/tactics/dn.ml b/tactics/dn.ml
index 07eb49442a..ebe88cd221 100644
--- a/tactics/dn.ml
+++ b/tactics/dn.ml
@@ -62,10 +62,10 @@ prefix ordering, [dna] is the function returning the main node of a pattern *)
pathrec []
let tm_of tm lbl =
- try [Trie.next tm lbl, true] with Not_found -> []
+ try [Trie.next tm lbl] with Not_found -> []
let rec skip_arg n tm =
- if Int.equal n 0 then [tm, true]
+ if Int.equal n 0 then [tm]
else
let labels = Trie.labels tm in
let map lbl = match lbl with
@@ -83,13 +83,11 @@ prefix ordering, [dna] is the function returning the main node of a pattern *)
tm_of tm None@
(List.fold_left
(fun l c ->
- List.flatten(List.map (fun (tm, b) ->
- if b then lookrec c tm
- else [tm,b]) l))
+ List.flatten(List.map (fun tm -> lookrec c tm) l))
(tm_of tm (Some(lbl,List.length v))) v)
| Everything -> skip_arg 1 tm
in
- List.flatten (List.map (fun (tm,b) -> ZSet.elements (Trie.get tm)) (lookrec t tm))
+ List.flatten (List.map (fun tm -> ZSet.elements (Trie.get tm)) (lookrec t tm))
let pattern dna pat = path_of dna pat