Skip to content

Commit

Permalink
make Pose constexpr
Browse files Browse the repository at this point in the history
  • Loading branch information
SizzinSeal committed Dec 28, 2024
1 parent 572e83b commit 23b0bc2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions include/units/Pose.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ template <typename derivatives> class AbstractPose
*
* This constructor initializes x, y, and orientation to 0
*/
AbstractPose() : Vector(), orientation(0.0) {}
constexpr AbstractPose() : Vector(), orientation(0.0) {}

/**
* @brief Construct a new Pose object
Expand All @@ -34,15 +34,15 @@ template <typename derivatives> class AbstractPose
*
* @param v position
*/
AbstractPose(Vector v) : Vector(v), orientation(0.0) {}
constexpr AbstractPose(Vector v) : Vector(v), orientation(0.0) {}

/**
* @brief Construct a new Pose object
*
* @param v position
* @param orientation orientation
*/
AbstractPose(Vector v, Divided<Angle, Exponentiated<Time, derivatives>> orientation)
constexpr AbstractPose(Vector v, Divided<Angle, Exponentiated<Time, derivatives>> orientation)
: Vector(v), orientation(orientation) {}

/**
Expand All @@ -53,7 +53,7 @@ template <typename derivatives> class AbstractPose
* @param x x position
* @param y y position
*/
AbstractPose(Len x, Len y) : Vector(x, y), orientation(0.0) {}
constexpr AbstractPose(Len x, Len y) : Vector(x, y), orientation(0.0) {}

/**
* @brief Construct a new Pose object
Expand All @@ -62,7 +62,7 @@ template <typename derivatives> class AbstractPose
* @param y y position
* @param orientation orientation
*/
AbstractPose(Len x, Len y, Divided<Angle, Exponentiated<Time, derivatives>> orientation)
constexpr AbstractPose(Len x, Len y, Divided<Angle, Exponentiated<Time, derivatives>> orientation)
: Vector(x, y), orientation(orientation) {}
};

Expand Down

0 comments on commit 23b0bc2

Please sign in to comment.