MCPcopy Create free account
hub / github.com/Gecode/gecode / cost

Method cost

gecode/kernel/core.hpp:4813–4825  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4811 PropCost::PropCost(PropCost::ActualCost ac0) : ac(ac0) {}
4812
4813 forceinline PropCost
4814 PropCost::cost(PropCost::Mod m,
4815 PropCost::ActualCost lo, PropCost::ActualCost hi,
4816 unsigned int n) {
4817 if (n < 2)
4818 return (m == LO) ? AC_UNARY_LO : AC_UNARY_HI;
4819 else if (n == 2)
4820 return (m == LO) ? AC_BINARY_LO : AC_BINARY_HI;
4821 else if (n == 3)
4822 return (m == LO) ? AC_TERNARY_LO : AC_TERNARY_HI;
4823 else
4824 return (m == LO) ? lo : hi;
4825 }
4826
4827 forceinline PropCost
4828 PropCost::record(void) {

Callers 1

enqueueMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected