Skip to content

Commit

Permalink
ros_context: add inline
Browse files Browse the repository at this point in the history
  • Loading branch information
erlenner committed Nov 25, 2021
1 parent a49edea commit 89d9e1f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tyndall/ros_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
// mock
namespace ros_context
{
int shutdown()
inline int shutdown()
{ return 0; }
int init(int argc, char** argv, std::chrono::milliseconds loop_sleep = std::chrono::milliseconds{3}, const char *node_name = "default_node_name")
inline int init(int argc, char** argv, std::chrono::milliseconds loop_sleep = std::chrono::milliseconds{3}, const char *node_name = "default_node_name")
{ return 0;}
}
#include <tyndall/ipc/ipc.h>
Expand All @@ -35,7 +35,7 @@ namespace ros_context

// methods

int shutdown()
inline int shutdown()
{
run_ros = 0;
ros_thread.join();
Expand All @@ -44,7 +44,7 @@ namespace ros_context
return 0;
}

int init(int argc, char** argv, std::chrono::milliseconds loop_sleep = std::chrono::milliseconds{3}, const char *node_name = "default_node_name")
inline int init(int argc, char** argv, std::chrono::milliseconds loop_sleep = std::chrono::milliseconds{3}, const char *node_name = "default_node_name")
{
assert(nh == NULL); // enforce single initialization per process

Expand Down

0 comments on commit 89d9e1f

Please sign in to comment.