`findall/3`: unexpected behavior in some cases
A file to consult:
fact(a).
fact(b).
facts(L) :- findall(X,fact(X),L).
Unexpected (too-much-non-monotonicity-like behaviour):
?- facts([a,B]).
false, unexpected.
B = b. % expected, but not found.
But:
?- facts([A,B]).
A = a, B = b. % as expected.
Could you please try it with the rebis-dev development branch? With it, I get:
?- facts([a,B]). B = b. % expected
My example was with: https://github.com/mthom/scryer-prolog/tree/d18ef52e67319e22694ac03c4301d0c6e5379196
I see, yes, it works as in your example with rebis-dev https://github.com/mthom/scryer-prolog/commit/6e0af25fcdcbeed35d7c3bc5cf9544bb61896b11
So, what does it mean? Should I close this?
I suggest you keep it open until it is resolved also in master (i.e., after rebis-dev is merged). Very nice catch!
Ok, thank you...