From b6cdb2a3953ec09fed05f053dceca44c28d74557 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 7 Oct 2024 22:13:59 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- include/eigenpy/angle-axis.hpp | 3 +-- include/eigenpy/decompositions/LLT.hpp | 5 +++-- include/eigenpy/fwd.hpp | 5 ++--- python/main.cpp | 4 ++-- unittest/complex.cpp | 26 ++++++++++++++------------ 5 files changed, 22 insertions(+), 21 deletions(-) diff --git a/include/eigenpy/angle-axis.hpp b/include/eigenpy/angle-axis.hpp index d0600c79b..84a5f2a2f 100644 --- a/include/eigenpy/angle-axis.hpp +++ b/include/eigenpy/angle-axis.hpp @@ -55,8 +55,7 @@ class AngleAxisVisitor : public bp::def_visitor > { bp::make_function((Vector3 & (AngleAxis::*)()) & AngleAxis::axis, bp::return_internal_reference<>()), &AngleAxisVisitor::setAxis, "The rotation axis.") - .add_property("angle", - (Scalar(AngleAxis::*)() const) & AngleAxis::angle, + .add_property("angle", (Scalar(AngleAxis::*)() const)&AngleAxis::angle, &AngleAxisVisitor::setAngle, "The rotation angle.") /* --- Methods --- */ diff --git a/include/eigenpy/decompositions/LLT.hpp b/include/eigenpy/decompositions/LLT.hpp index abf898ec3..cb460c01a 100644 --- a/include/eigenpy/decompositions/LLT.hpp +++ b/include/eigenpy/decompositions/LLT.hpp @@ -54,8 +54,9 @@ struct LLTSolverVisitor bp::args("self", "vector", "sigma"), bp::return_self<>()) #else .def("rankUpdate", - (Solver(Solver::*)(const VectorXs &, const RealScalar &)) & - Solver::template rankUpdate, + (Solver(Solver::*)( + const VectorXs &, + const RealScalar &))&Solver::template rankUpdate, bp::args("self", "vector", "sigma")) #endif diff --git a/include/eigenpy/fwd.hpp b/include/eigenpy/fwd.hpp index acc8edc11..23b1a31fb 100644 --- a/include/eigenpy/fwd.hpp +++ b/include/eigenpy/fwd.hpp @@ -43,9 +43,8 @@ EIGENPY_PRAGMA_WARNING(Deprecated : the_message) #define EIGENPY_PRAGMA_DEPRECATED_HEADER(old_header, new_header) \ EIGENPY_PRAGMA_WARNING( \ - Deprecated header file \ - : #old_header has been replaced \ - by #new_header.\n Please use #new_header instead of #old_header.) + Deprecated header file : #old_header has been replaced \ + by #new_header.\n Please use #new_header instead of #old_header.) #elif defined(WIN32) #define EIGENPY_PRAGMA(x) __pragma(#x) #define EIGENPY_PRAGMA_MESSAGE(the_message) \ diff --git a/python/main.cpp b/python/main.cpp index 6d39d1612..966bb7998 100644 --- a/python/main.cpp +++ b/python/main.cpp @@ -32,8 +32,8 @@ void exposeIsApprox() { bp::def("is_approx", (bool (*)(const Eigen::MatrixBase &, - const Eigen::MatrixBase &, const RealScalar &)) & - is_approx, + const Eigen::MatrixBase &, + const RealScalar &))&is_approx, (bp::arg("A"), bp::arg("B"), bp::arg("prec") = dummy_precision), "Returns True if A is approximately equal to B, within the " "precision determined by prec."); diff --git a/unittest/complex.cpp b/unittest/complex.cpp index 919dc3e71..9595f2a00 100644 --- a/unittest/complex.cpp +++ b/unittest/complex.cpp @@ -69,17 +69,19 @@ BOOST_PYTHON_MODULE(complex) { bp::def("ascomplex", ascomplex); - bp::def("real", (MatrixXf(*)(const Eigen::MatrixBase &)) & - real); - bp::def("real", (MatrixXd(*)(const Eigen::MatrixBase &)) & - real); - bp::def("real", (MatrixXld(*)(const Eigen::MatrixBase &)) & - real); + bp::def("real", + (MatrixXf(*)(const Eigen::MatrixBase &))&real); + bp::def("real", + (MatrixXd(*)(const Eigen::MatrixBase &))&real); + bp::def( + "real", + (MatrixXld(*)(const Eigen::MatrixBase &))&real); - bp::def("imag", (MatrixXf(*)(const Eigen::MatrixBase &)) & - imag); - bp::def("imag", (MatrixXd(*)(const Eigen::MatrixBase &)) & - imag); - bp::def("imag", (MatrixXld(*)(const Eigen::MatrixBase &)) & - imag); + bp::def("imag", + (MatrixXf(*)(const Eigen::MatrixBase &))&imag); + bp::def("imag", + (MatrixXd(*)(const Eigen::MatrixBase &))&imag); + bp::def( + "imag", + (MatrixXld(*)(const Eigen::MatrixBase &))&imag); }