ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

This is a little bit of a hack but would have the desired effect.

string costly_method_wrapper()
{
//Costly stuff in here
return std::string(); // or real debugging info here.
}
ROS_DEBUG_STREAM("my output is " << costly_method_wrapper() << " other debug info");