diff --git a/cpp/VectorConfig.cpp b/cpp/VectorConfig.cpp index 338026fa8..c37875c1b 100644 --- a/cpp/VectorConfig.cpp +++ b/cpp/VectorConfig.cpp @@ -35,12 +35,6 @@ std::vector VectorConfig::get_names() const { return names; } -/* ************************************************************************* */ -VectorConfig& VectorConfig::insert(const Symbol& name, const Vector& val) { - values.insert(std::make_pair(name,val)); - return *this; -} - /* ************************************************************************* */ void VectorConfig::insert(const VectorConfig& config) { for (const_iterator it = config.begin(); it!=config.end(); it++) { diff --git a/cpp/VectorConfig.h b/cpp/VectorConfig.h index d6f6f9ff1..96637d537 100644 --- a/cpp/VectorConfig.h +++ b/cpp/VectorConfig.h @@ -40,7 +40,10 @@ namespace gtsam { std::vector get_names() const; /** Insert a value into the configuration with a given index */ - VectorConfig& insert(const Symbol& name, const Vector& val); + inline VectorConfig& insert(const Symbol& name, const Vector& val) { + values.insert(std::make_pair(name,val)); + return *this; + } /** Insert a config into another config */ void insert(const VectorConfig& config);