Variable = (C.J =: I) %First
Contrainte = (C.J \=: {self getForbiddenValue(C.J)}) %Second
Doesn't this block? Why don't you use
Contrainte = (C.J \=: {self getForbiddenValue(I)})
I doesn't block as far as I know ...
I mean, as C.J is probably a FD variable, I think that the constraint
"C.J \=: {self getForbiddenValue(C.J)}" can not be computed before C.J
is known, so the whole statement blocks (or, if this runs in its own
thread, the {FD.impl ...} statement blocks). Like
local
fun {Incr X}
X+1
end
X={FD.int 0#10}
in
{FD.impl (X=:0) (1 =: {Incr X}) 1}
{Show done}
end
never prints "done" because Incr waits for X to be known. I thought that
getForbiddenValue accesses its argument.
If I am wrong, could someone correct me, please?
Cheers,
Filip
_________________________________________________________________________________
mozart-users mailing list
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users