error: ISO C++ forbids declaration of ‘type name’ with no type [-fpermissive] Eigen::Map<const g2o::Vector7d> v(m); [closed]
when compiling LSD-slam on my laptop, I received these unexpected errors
Actually, the source is coming from the part of an open source project I try to rerun. I did it before several days ago. However, I encounter this problem yesterday. here are my steps as below
cd catkin_ws
catkin_make
GlobalMapping/g2oTypeSim3Sophus.h:96:20: error: ISO C++ forbids declaration of ‘type name’ with no type [-fpermissive]
Eigen::Map<const g2o::Vector7d> v(m);
^~~
/home/htf/catkin_ws/src/third_parties/lsd_slam/lsd_slam_core/src/GlobalMapping/g2oTypeSim3Sophus.h:96:33: error: template argument 1 is invalid
Eigen::Map<const g2o::Vector7d> v(m);
^
/home/htf/catkin_ws/src/third_parties/lsd_slam/lsd_slam_core/src/GlobalMapping/g2oTypeSim3Sophus.h:96:38: error: invalid conversion from ‘const double*’ to ‘int’ [-fpermissive]
Eigen::Map<const g2o::Vector7d> v(m);
^
/home/htf/catkin_ws/src/third_parties/lsd_slam/lsd_slam_core/src/GlobalMapping/g2oTypeSim3Sophus.h:97:38: error: no matching function for call to ‘Sophus::Sim3Group<double>::exp(int&)’
setMeasurement(Sophus::Sim3d::exp(v));
does anyone has encountered this problem? hope to get some clues, Thank you in advance.
Do you mean compiling not running? Can you tell us how you downloaded the source, setup your work space, and tried to build it.
@PeteBlackerThe3rd I have edited my question, thank you for your comment
@tengfei hanhttps://github.com/tum-vision/lsd_sla... or https://github.com/tum-vision/lsd_sla... PR might help you