data: add not equal operator

parent 46e29db9
......@@ -299,6 +299,13 @@ namespace pinocchio
;
}
template<typename Scalar, int Options, template<typename,int> class JointCollectionTpl>
bool operator!=(const DataTpl<Scalar,Options,JointCollectionTpl> & data1,
const DataTpl<Scalar,Options,JointCollectionTpl> & data2)
{
return !(data1 == data2);
}
} // namespace pinocchio
/// @endcond
......
......@@ -75,6 +75,9 @@ BOOST_AUTO_TEST_SUITE(BOOST_TEST_MODULE)
BOOST_CHECK(data == data);
BOOST_CHECK(data == data_copy);
data_copy.oMi[0].setRandom();
BOOST_CHECK(data != data_copy);
}
BOOST_AUTO_TEST_SUITE_END()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment