diff --git a/unittest/vector.cpp b/unittest/vector.cpp index f18fa5f20c752ab5efa2f808097a59408379fbf7..6941b3843a1b201459e4ef577b6b4f42b94a3bbf 100644 --- a/unittest/vector.cpp +++ b/unittest/vector.cpp @@ -1,11 +1,10 @@ -#include "eigenpy/eigenpy.hpp" -#include "eigenpy/std-vector.hpp" - - #include <ostream> #include <type_traits> -template<typename MatType> +#include "eigenpy/eigenpy.hpp" +#include "eigenpy/std-vector.hpp" + +template <typename MatType> void printVectorOfMatrix(const std::vector<MatType> &Ms) { const std::size_t n = Ms.size(); for (std::size_t i = 0; i < n; i++) { @@ -13,13 +12,12 @@ void printVectorOfMatrix(const std::vector<MatType> &Ms) { } } -template<typename MatType> +template <typename MatType> std::vector<MatType> copy(const std::vector<MatType> &Ms) { std::vector<MatType> out = Ms; return out; } - BOOST_PYTHON_MODULE(vector) { namespace bp = boost::python; @@ -31,8 +29,8 @@ BOOST_PYTHON_MODULE(vector) { bp::def("copyStdVector", copy<Eigen::MatrixXd>); bp::def("copyStdVector", copy<Eigen::VectorXd>); - eigenpy::StdVectorPythonVisitor<std::vector<Eigen::Matrix3d>>::expose("StdVec_Mat3d", "3D matrices."); + eigenpy::StdVectorPythonVisitor<std::vector<Eigen::Matrix3d>>::expose( + "StdVec_Mat3d", "3D matrices."); bp::def("printVectorOf3x3", printVectorOfMatrix<Eigen::Matrix3d>); bp::def("copyStdVec_3x3", copy<Eigen::Matrix3d>, bp::args("mats")); - }