Skip to content

Commit

Permalink
Fixed some warnings that would be triggered in downstream packages in…
Browse files Browse the repository at this point in the history
…cluding header files from this repo when building with the '-Wall -Wextra -Wpedantic' compiler flags.
  • Loading branch information
yvaind committed Mar 29, 2019
1 parent ac4bc0c commit 5d41805
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ class ExecutorState
virtual ~ExecutorState();

void setState(size_t stepNumber, double stepPhase);
const size_t stepNumber() const;
const double stepPhase() const;
size_t stepNumber() const;
double stepPhase() const;

friend bool operator>(const ExecutorState& stateA, const ExecutorState& stateB);
friend bool operator<=(const ExecutorState& stateA, const ExecutorState& stateB);
Expand Down
4 changes: 2 additions & 2 deletions free_gait_core/src/executor/ExecutorState.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ void ExecutorState::setState(size_t stepNumber, double stepPhase)
stepPhase_ = stepPhase;
}

const size_t ExecutorState::stepNumber() const
size_t ExecutorState::stepNumber() const
{
return stepNumber_;
}

const double ExecutorState::stepPhase() const
double ExecutorState::stepPhase() const
{
return stepPhase_;
}
Expand Down
3 changes: 3 additions & 0 deletions free_gait_ros/include/free_gait_ros/FreeGaitActionClient.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@
#include <free_gait_msgs/ExecuteActionFeedback.h>

// ROS
#pragma GCC diagnostic push // Get rid of compiler warnings we can't fix.
#pragma GCC diagnostic ignored "-Wpedantic"
#include <actionlib/client/simple_action_client.h>
#pragma GCC diagnostic pop // Back to normal warning handling.
#include <tf2_ros/transform_listener.h>

// STD
Expand Down

0 comments on commit 5d41805

Please sign in to comment.