Errors importing old projects in eclipse
Hi, I followed this wiki http://www.ros.org/wiki/IDEs to start using eclipse while developing my ros nodes. I started importing an old node I developed a couple of weeks ago but it seems that eclipse cannot resolve subscribe. Here's my code that fails:
cmd_vel_sub_ = node_.subscribe <geometry_msgs::Twist>(sub_cmd_vel, 1, boost::bind(&RosListenNode::twist_pub, this, _1));
and here's the error I get:
Description Resource Path Location Type
Invalid arguments '
Candidates are:
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(#0), #1 *, const ros::TransportHints &)
ros::Subscriber subscribe(ros::SubscribeOptions &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(#0)const, #1 *, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(const boost::shared_ptr<const #0> &), #1 *, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(const boost::shared_ptr<const #0> &)const, #1 *, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(#0), const boost::shared_ptr<#1> &, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(#0)const, const boost::shared_ptr<#1> &, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(const boost::shared_ptr<const #0> &), const boost::shared_ptr<#1> &, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (#1::*)(const boost::shared_ptr<const #0> &)const, const boost::shared_ptr<#1> &, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (*)(#0), const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, void (*)(const boost::shared_ptr<const #0> &), const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, const boost::function<void (const boost::shared_ptr<const #0> &)> &, const boost::shared_ptr<const void> &, const ros::TransportHints &)
ros::Subscriber subscribe(const std::basic_string<char,std::char_traits<char>,std::allocator<char>> &, unsigned int, const boost::function<void (#1)> &, const boost::shared_ptr<const void> &, const ros::TransportHints &)
' bridge.cpp /RosToPlatform-RelWithDebInfo@RosToPlatform/src line 134 Semantic Error
Any idea on how to solve this problem?
A weird thing, if I remove the boost:bind call and substitute it with NULL I get no errors. So I thought it was a problem with boost but if I add
boost::bind(&RosListenNode::twist_pub, this, _1); it doesn't result as an error.It seems like eclipse is having problems with the templates