ros-gbp / bfl-release

Release of Bayesian Filtering Library for ROS
25 stars 20 forks source link

Update mixtureParticleFilter.cpp #2

Closed Lenskiy closed 11 years ago

Lenskiy commented 11 years ago

I am getting compilation errors when building with clang on Mac. Here the log

In file included from /Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.h:375:
/Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.cpp:105:27: error: member reference base type 'Mixture<SVar> *' is not a structure or union
  for(int i =0 ; i < prior.NumComponentsGet() ; i++)
                     ~~~~~^~~~~~~~~~~~~~~~~
/Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.cpp:111:27: error: member reference base type 'Mixture<SVar> *' is not a structure or union
  for(int i =0 ; i < prior.NumComponentsGet() ; i++)
                     ~~~~~^~~~~~~~~~~~~~~~~
/Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.cpp:113:32: error: member reference base type 'Mixture<SVar> *' is not a structure or union
    _old_samplesVec[i] = (prior.ComponentGet(i)->ListOfSamplesGet());
                          ~~~~~^~~~~~~~~~~~~
/Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.cpp:362:16: warning: self-comparison always evaluates to true [-Wtautological-compare]
        result == result && this->DynamicResampleStepOne(i);
               ^
/Users/me/ros/catkin_install/src/bfl/src/filter/mixtureParticleFilter.cpp:451:16: warning: self-comparison always evaluates to true [-Wtautological-compare]
        result == result && this->ResampleOne(i);
               ^

To solve this issue I had to change . operator to -> at mixtureParticleFilter.cpp:105, mixtureParticleFilter.cpp:111, mixtureParticleFilter.cpp:113.

tfoote commented 11 years ago

Thanks for taking the time to put together a patch, unfortunately this is the packaging repository for bfl in ROS. This would be the right tracker for packaging issues. However, this appears to be a bug in the upstream code. Please submit it upstream to the orocos project http://www.orocos.org/bfl Their bug tracker is here: http://bugs.orocos.org/enter_bug.cgi?product=BFL There the maintainers can review your patch and hopefully apply it to BFL.

When there's a new release you could open a ticket here to ask for it to be repackaged with the patched version.