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

Output of file & line position of warnings in the MiniZinc IDE output window. #212

Open
forceoffire opened this issue Feb 13, 2025 · 1 comment
Labels
bug resolved Issue is resolved and the feature or fix will be part of next release

Comments

@forceoffire
Copy link

With the latest update of MiniZinc to version 2.9.0 the implicit conversion of enums to ints emits a warning with the requirement that the user makes the conversion explicit using enum2int. Currently, in the IDE the warnings do not contain file/line-number/column information (as is typical for errors), although it is available when minizinc is run from the command-line. I have also tried using -Werror, to convert the warnings to errors, but it does not change the output in the IDE. When compilation errors arise in the IDE, the user can find the location of where the changes need to be made directly by clicking on the provided link to the file in the output window, facilitating the process of systematically fixing errors. As such, it would be helpful if

(1) warnings also emit the file/line-number/column information in the output window from where it can be found in the mzn files for fixing and
(2) the user can add a command-line parameter that tells MiniZinc to emit all warnings rather than stopping after a few.

@cyderize cyderize added the bug label Feb 13, 2025
guidotack pushed a commit that referenced this issue Feb 18, 2025
Fallback to using location instead.

Fixes #212
@cyderize cyderize added the resolved Issue is resolved and the feature or fix will be part of next release label Feb 18, 2025
@cyderize
Copy link
Member

cyderize commented Feb 18, 2025

Thanks! The issue with warning locations not being shown in the IDE will be fixed in the next release (or you can use the edge release to test out the fix now).

I've opened MiniZinc/libminizinc#883 to track the feature request for emitting all warnings.

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