Skip to content

Preserve Gist mode with statistics#232

Merged
zayenz merged 3 commits into
mainfrom
feature/preserve-gist-mode
Jul 14, 2026
Merged

Preserve Gist mode with statistics#232
zayenz merged 3 commits into
mainfrom
feature/preserve-gist-mode

Conversation

@zayenz

@zayenz zayenz commented Jul 13, 2026

Copy link
Copy Markdown
Member

FlatZinc option parsing changed the execution mode to stat whenever -s was present, even when -mode gist had been selected explicitly. Argument order did not help because the override happened after parsing.

Keep -s as the statistics shorthand for ordinary solution mode, but preserve an explicit Gist mode in either argument order.

When Gist support is compiled out, reject Gist execution before search with a clear FlatZinc error instead of silently falling through to ordinary solution mode. The run-level regression parses and prepares a real model, then verifies that -mode gist -s raises the unavailable-mode error without producing a solution.

The focused FlatZinc option tests are included in both the CMake and Autotools fast-check selections.

Checks:

  • Gist-disabled CMake Release build of fzn-gecode and gecode-test
  • FlatZinc::Options::GistStatisticsMode
  • FlatZinc::Options::GistUnavailable
  • Gist-disabled fzn-gecode -mode gist -s process exits 1 with the expected error
  • Gist-enabled CMake Release build of fzn-gecode
  • git diff --check

Closes #99.

@zayenz zayenz marked this pull request as ready for review July 14, 2026 08:12
@zayenz zayenz force-pushed the feature/preserve-gist-mode branch from c277ac6 to e537646 Compare July 14, 2026 08:16
@zayenz zayenz merged commit 73422e6 into main Jul 14, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant