[gecode-users] seg fault with posting dom constraint

Kish Shen kisshen at cisco.com
Mon Jun 29 22:20:37 CEST 2009


I should have looked at the problem more before posting. It seems that 
the problem is in the way I assign the IntVarArg:

> vars[0] = solver->vInt[0];

which is actually done via a call to a procedure, something like:

int assign(GecodeSpace* solver, IntVarArgs vars) {
	vars[0] = solver->vInt[0];
}
...
IntVarArgs vars[1];
assign(solver, vars);

dom(*solver, vars);

I assume I cannot pass IntVarArgs vars in the way I am doing -- this is 
probably due to my C background, I had assumed that IntVarArgs is an 
array, I can just pass it and any changes to its elements will be seen 
in the parent, but I guess this is not correct?

--Kish



-- 
This e-mail may contain confidential and privileged material for the
sole use of the intended recipient. Any review, use, distribution or
disclosure by others is strictly prohibited. If you are not the intended
recipient (or authorized to receive for the recipient), please contact
the sender by reply e-mail and delete all copies of this message.
Cisco Systems Limited (Company Number: 02558939), is registered in
England and Wales with its registered office at 1 Callaghan Square,
Cardiff, South Glamorgan CF10 5BT.




More information about the gecode-users mailing list