Hi Philippe, Both are not possible due to restrictions in C++...
Cheers Christian -- Christian Schulte, Professor of Computer Science, KTH, www.ict.kth.se/~cschulte/ -----Original Message----- From: users-boun...@gecode.org [mailto:users-boun...@gecode.org] On Behalf Of Philippe Sent: Wednesday, June 04, 2014 8:12 PM To: users@gecode.org Subject: Re: [gecode-users] Help to express a constraint Sorry for the wrong form i've provided. Here is an example of what i wanted to express : 1) Given the fact that Status and Succ are matrix interfaces of two IntVarArray and t, m are integers, the expression : expr(*this, Status(Succ(t,m), m) != 3); // don't compile is more "elegant" than : expr(*this, element(Status.row(m), Succ(t,m)) != 3) But it seems difficult to implement the first one. 2) I have another exemple in mind : expr(*this, Succ(t,m) != t); // don't compile For now, one have to write this to compile : IntVar T(*this, t, t); expr(*this, Succ(t,m) != T); Anyway, it's just syntaxic sugar... sorry to bother you with these remarks. Best, Philippe _______________________________________________ Gecode users mailing list users@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users _______________________________________________ Gecode users mailing list users@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users