Skip to content
Snippets Groups Projects

ENH: Use std::move instead of boost::move

Merged Laurențiu Nicola requested to merge std-move into develop
5 files
+ 12
29
Compare changes
  • Side-by-side
  • Inline
Files
5
@@ -46,7 +46,7 @@ inline
/*virtual*/
void
otb::DefaultGeometriesToGeometriesFilter<TransformationFunctor, FieldTransformationPolicy>::DoProcessLayer(otb::ogr::Layer const& source,
otb::ogr::Layer& destination) const
otb::ogr::Layer& destination) const
{
if (source != destination)
{
@@ -83,15 +83,14 @@ inline void otb::TransformationFunctorDispatcher<TransformationFunctor, otb::ogr
/*===========================================================================*/
template <class TransformationFunctor, class FieldTransformationPolicy>
inline void otb::TransformationFunctorDispatcher<TransformationFunctor, OGRGeometry, FieldTransformationPolicy>::operator()(otb::ogr::Layer const& in,
otb::ogr::Layer& out) const
otb::ogr::Layer& out) const
{
OGRFeatureDefn& defn = out.GetLayerDefn();
for (ogr::Layer::const_iterator b = in.begin(), e = in.end(); b != e; ++b)
{
ogr::Feature const feat = *b;
ogr::UniqueGeometryPtr g = m_functor(feat.GetGeometry());
ogr::Feature dest(defn);
dest.SetGeometryDirectly(otb::move(g));
ogr::Feature const feat = *b;
ogr::Feature dest(defn);
dest.SetGeometryDirectly(m_functor(feat.GetGeometry()));
this->fieldsTransform(feat, dest);
out.CreateFeature(dest);
}
@@ -108,8 +107,7 @@ inline void otb::TransformationFunctorDispatcher<TransformationFunctor, OGRGeome
{
ogr::Feature feat = *inout.start_at(i);
this->fieldsTransform(feat);
ogr::UniqueGeometryPtr g = m_functor(feat.GetGeometry());
feat.SetGeometryDirectly(otb::move(g));
feat.SetGeometryDirectly(m_functor(feat.GetGeometry()));
inout.SetFeature(feat);
}
}
Loading