From d96386684e06473c5fbce2707052cf1732831d5c Mon Sep 17 00:00:00 2001 From: Claudio Sacerdoti Coen Date: Thu, 29 Jul 2010 15:27:13 +0000 Subject: [PATCH] Bug fixed: nodes were copied. --- helm/software/components/disambiguation/disambiguate.ml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/helm/software/components/disambiguation/disambiguate.ml b/helm/software/components/disambiguation/disambiguate.ml index d0d7460a6..5b5b53f52 100644 --- a/helm/software/components/disambiguation/disambiguate.ml +++ b/helm/software/components/disambiguation/disambiguate.ml @@ -453,10 +453,11 @@ let disambiguate_thing let rec aux (aliases,acc) = function | [] -> aliases, acc | (Node (_, item,extra) as node) :: tl -> - let tl = tl @ extra in let choices = lookup_choices item in if List.length choices <> 1 then aux (aliases, acc@[node]) tl - else if Environment.mem item aliases then aux (aliases, acc) tl + else + let tl = tl @ extra in + if Environment.mem item aliases then aux (aliases, acc) tl else aux (Environment.add item (List.hd choices) aliases, acc) tl in aux (aliases,[]) todo_dom -- 2.39.2