ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Technically, the old C++ standard says that non-integer constant data is illegal in class declarations. The easy way to fix this is to define it in the source file. I fixed it by moving the definition of DEFAULT_CACHE_TIME to tf.cpp and it now works with GCC 4.4.5 on Debian 6.0.4, no --std argument needed. I'm pretty sure it will also work in C++0x. constexpr is more for template metaprogramming and places where you can't separate the definition from the declaration, or would like to make something constant for performance tuning.