-
Type: Improvement
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Execution
Use generalized helper function for SBE stages debugPrint().
// Help debugPrinter to print an optional slot. void addDebugOptionalSlotIdentifier(std::vector<DebugPrinter::Block>& ret, const boost::optional<value::SlotId>& slot) { if (slot) { DebugPrinter::addIdentifier(ret, slot.value()); } else { DebugPrinter::addIdentifier(ret, DebugPrinter::kNoneKeyword); } } // Help debugPrinter to print a vector of slots. void addDebugSlotVector(std::vector<DebugPrinter::Block>& ret, const value::SlotVector& slotVec) { ret.emplace_back(DebugPrinter::Block("[`")); for (size_t idx = 0; idx < slotVec.size(); ++idx) { if (idx) { ret.emplace_back(DebugPrinter::Block("`,")); } DebugPrinter::addIdentifier(ret, slotVec[idx]); } ret.emplace_back(DebugPrinter::Block("`]")); }