tests/spec/unit/compilation/struct_table.mzn
raw| 1 | /*** |
| 2 | !Test |
| 3 | type: compile |
| 4 | solvers: [gecode] |
| 5 | expected: !FlatZinc struct_table.fzn |
| 6 | ***/ |
| 7 | |
| 8 | enum E = {A,B,C}; |
| 9 | type T = tuple(int, E, record(int: z, bool: a)); |
| 10 | |
| 11 | var T: x; |
| 12 | array[_] of T: xs = [ |
| 13 | (1, A, (z: 3, a: true)), |
| 14 | (2, B, (z: 6, a: false)), |
| 15 | (3, C, (z: 9, a: false)), |
| 16 | ]; |
| 17 | |
| 18 | constraint x in xs; |