fix findall/4 (#873)
This commit is contained in:
@@ -682,9 +682,8 @@ findall(Template, Goal, Solutions) :-
|
||||
).
|
||||
|
||||
|
||||
% :- meta_predicate '$iterate_find_all_diff'(?, 0, ?, ?, ?).
|
||||
|
||||
:- non_counted_backtracking '$iterate_find_all_diff'/5.
|
||||
|
||||
'$iterate_find_all_diff'(Template, Goal, _, _, LhOffset) :-
|
||||
call(Goal),
|
||||
'$copy_to_lh'(LhOffset, Template),
|
||||
|
||||
@@ -3267,8 +3267,7 @@ impl MachineState {
|
||||
let solutions = self[temp_v!(2)];
|
||||
let diff = self[temp_v!(3)];
|
||||
|
||||
(self.unify_fn)(self, solutions, Addr::EmptyList);
|
||||
(self.unify_fn)(self, diff, Addr::EmptyList);
|
||||
(self.unify_fn)(self, solutions, diff);
|
||||
} else {
|
||||
let h = self.heap.h();
|
||||
let mut last_index = h;
|
||||
|
||||
Reference in New Issue
Block a user