Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.8.1: Evaluation error when flattening ground instance #758

Closed
informarte opened this issue Nov 30, 2023 · 0 comments
Closed

2.8.1: Evaluation error when flattening ground instance #758

informarte opened this issue Nov 30, 2023 · 0 comments
Labels
bug resolved Issue is resolved and the feature or fix will be part of next release

Comments

@informarte
Copy link

Consider this problem:

include "lex_less.mzn";

int: N = 10;
int: M = 9;

array [1..N] of var bool: x;
array [1..N] of var bool: y;

constraint x = [true, true, true, true, true, true, true, true, true, false];
constraint y = [true, true, true, true, true, true, true, true, true, true];

constraint lex_less(x, y);
constraint forall(i in 1..M)(x[i] = true);

solve satisfy;

output ["x = ", show(x), "\n", "y = ", show(y)]

MiniZinc 2.7.6 outputs the solution as expected:

x = [true, true, true, true, true, true, true, true, true, false]
y = [true, true, true, true, true, true, true, true, true, true]
----------

MiniZinc 2.8.1, however, fails with this error message:

Error: evaluation error: cannot evaluate expression 'X_INTRODUCED_0_'
bug.mzn:13.12-41
  in call 'forall'
  in array comprehension expression
    with i = 1
  in binary '=' operator expression
  in array access
@cyderize cyderize added the bug label Nov 30, 2023
@cyderize cyderize added the resolved Issue is resolved and the feature or fix will be part of next release label Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug resolved Issue is resolved and the feature or fix will be part of next release
Projects
None yet
Development

No branches or pull requests

2 participants