From 84b42ed3920a02feb6dd0e424a0aa02df8a50edb Mon Sep 17 00:00:00 2001 From: Varun Agrawal Date: Mon, 18 Sep 2023 22:54:23 -0400 Subject: [PATCH] use the string argument in DiscreteKeys::print --- gtsam/discrete/DiscreteKey.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/gtsam/discrete/DiscreteKey.cpp b/gtsam/discrete/DiscreteKey.cpp index 79d11d8a7..17f233695 100644 --- a/gtsam/discrete/DiscreteKey.cpp +++ b/gtsam/discrete/DiscreteKey.cpp @@ -49,6 +49,7 @@ namespace gtsam { void DiscreteKeys::print(const std::string& s, const KeyFormatter& keyFormatter) const { + std::cout << (s.empty() ? "" : s + " ") << std::endl; for (auto&& dkey : *this) { std::cout << DefaultKeyFormatter(dkey.first) << " " << dkey.second << std::endl;