| 1 |
/*** |
| 2 |
--- !Test |
| 3 |
type: compile |
| 4 |
solvers: [gecode] |
| 5 |
expected: !FlatZinc aggregation.fzn |
| 6 |
***/ |
| 7 |
|
| 8 |
% This tests is dependend on the successful aggregation of sum(xs) into the |
| 9 |
% int_lin_le expression and the removal of intermediate value for sum(xs) that |
| 10 |
% is created |
| 11 |
|
| 12 |
array[1..2] of var 1..4: xs; |
| 13 |
|
| 14 |
predicate my_lin(array [int] of int: as,array [int] of var int: bs,int: c); |
| 15 |
predicate int_lin_eq(array [int] of int: as,array [int] of var int: bs,int: c) |
| 16 |
= my_lin(as, bs, c); |
| 17 |
|
| 18 |
constraint sum(xs) <= 5; |