[BUGFIX] fix wrong children quantity in debug string (#10348)

This commit is contained in:
Gabriel
2022-06-23 09:10:30 +08:00
committed by GitHub
parent 274a0f2603
commit ed1e130ef6

View File

@ -39,11 +39,14 @@ public:
}
}
virtual std::string debug_string() const override {
std::string debug_string() const override {
std::stringstream out;
out << "CompoundPredicate {(";
out << _children[0]->debug_string() << ") " << _fn.name.function_name << " (";
out << _children[1]->debug_string() << ")}";
out << "CompoundPredicate {" << _fn.name.function_name;
out << " (" << _children[0]->debug_string();
if (children().size() > 1) {
out << ", " << _children[1]->debug_string();
}
out << ")}";
return out.str();
}
};