| 1 |
/*** |
| 2 |
!Test |
| 3 |
expected: |
| 4 |
- !Result |
| 5 |
solution: !Solution |
| 6 |
P: -2147483645 |
| 7 |
Q: -2147483644 |
| 8 |
R: -2147483646 |
| 9 |
- !Result |
| 10 |
solution: !Solution |
| 11 |
P: 1 |
| 12 |
Q: 2 |
| 13 |
R: 0 |
| 14 |
- !Result |
| 15 |
solution: !Solution |
| 16 |
P: -499999999 |
| 17 |
Q: -499999998 |
| 18 |
R: -500000000 |
| 19 |
***/ |
| 20 |
|
| 21 |
% Regression test for bug #282: mzn2fzn's optimization pass left dangling |
| 22 |
% variables in the int_search/4 annotation below. |
| 23 |
|
| 24 |
var int : P; |
| 25 |
var int : Q; |
| 26 |
var int : R; |
| 27 |
constraint ((R + 1) = P); |
| 28 |
constraint ((R + 2) = Q); |
| 29 |
solve :: seq_search([int_search([P,Q,R], input_order, indomain_min, complete)]) |
| 30 |
satisfy; |
| 31 |
output [ |
| 32 |
"P = ", show(P), "\n", |
| 33 |
"Q = ", show(Q), "\n", |
| 34 |
"R = ", show(R), "\n" |
| 35 |
]; |