Don't use c99 feature :-/
parent
1594a25045
commit
d53b48cf80
|
@ -39,10 +39,8 @@ struct SearchNode {
|
||||||
* @brief Construct the root node for the search.
|
* @brief Construct the root node for the search.
|
||||||
*/
|
*/
|
||||||
static SearchNode Root(size_t numConditionals, double bound) {
|
static SearchNode Root(size_t numConditionals, double bound) {
|
||||||
return {.assignment = DiscreteValues(),
|
return {DiscreteValues(), 0.0, bound,
|
||||||
.error = 0.0,
|
static_cast<int>(numConditionals) - 1};
|
||||||
.bound = bound,
|
|
||||||
.nextConditional = static_cast<int>(numConditionals) - 1};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Compare {
|
struct Compare {
|
||||||
|
@ -74,10 +72,8 @@ struct SearchNode {
|
||||||
newAssignment[key] = value;
|
newAssignment[key] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
return {.assignment = newAssignment,
|
return {newAssignment, error + conditional.error(newAssignment), 0.0,
|
||||||
.error = error + conditional.error(newAssignment),
|
nextConditional - 1};
|
||||||
.bound = 0.0,
|
|
||||||
.nextConditional = nextConditional - 1};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue