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

annotation functions #53

Closed
jnmonette opened this Issue Sep 18, 2015 · 2 comments

Comments

Projects
None yet
2 participants
@jnmonette

jnmonette commented Sep 18, 2015

Hi,

I am trying to use annotation functions but I ran accross some problem. Here is my code:

annotation simpleann;
annotation composeann(ann: s);
function ann: annfunc(ann: s) = composeann(s);
solve :: annfunc(composeann(simpleann)) satisfy;

The annotation function works fine if the passed annotation does not take any argument but it crashes if the passed annotation takes an argument as in the example above. The error message is:

mzn2fzn: /home/janho/programs/libminizinc/include/minizinc/ast.hh:198: T* MiniZinc::Expression::cast() [with T = MiniZinc::VarDecl]: Assertion `isa<T>()' failed.
Aborted

Is this a bug or am I simply hitting the limits of mzn2fzn?

@guidotack

This comment has been minimized.

Member

guidotack commented Sep 20, 2015

That's a bug (just fixed it).

@jnmonette

This comment has been minimized.

jnmonette commented Sep 21, 2015

Bug fixed over the week-end... That's great, thank you!

@guidotack guidotack closed this in 3c3c7b1 Sep 29, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment