diff --git a/gtsam/inference/FactorGraph-inl.h b/gtsam/inference/FactorGraph-inl.h index caf18d60e..66c44db52 100644 --- a/gtsam/inference/FactorGraph-inl.h +++ b/gtsam/inference/FactorGraph-inl.h @@ -108,15 +108,15 @@ namespace gtsam { } /* ************************************************************************* */ - template - typename DERIVED::shared_ptr Combine(const FactorGraph& factors, + template + typename DERIVEDFACTOR::shared_ptr Combine(const FactorGraph& factors, const FastMap >& variableSlots) { typedef const std::pair > KeySlotPair; // Local functional for getting keys out of key-value pairs struct Local { static KEY FirstOf(const KeySlotPair& pr) { return pr.first; } }; - return typename DERIVED::shared_ptr(new DERIVED( + return typename DERIVEDFACTOR::shared_ptr(new DERIVEDFACTOR( boost::make_transform_iterator(variableSlots.begin(), &Local::FirstOf), boost::make_transform_iterator(variableSlots.end(), &Local::FirstOf))); } diff --git a/gtsam/inference/FactorGraph.h b/gtsam/inference/FactorGraph.h index d0b9952d5..5295a4c58 100644 --- a/gtsam/inference/FactorGraph.h +++ b/gtsam/inference/FactorGraph.h @@ -215,8 +215,8 @@ template class BayesTree; }; // FactorGraph /** Create a combined joint factor (new style for EliminationTree). */ - template - typename DERIVED::shared_ptr Combine(const FactorGraph& factors, + template + typename DERIVEDFACTOR::shared_ptr Combine(const FactorGraph& factors, const FastMap >& variableSlots); /**