On 11 April 2018 at 14:40, Even Rouault <even.roua...@spatialys.com> wrote:
> On mercredi 11 avril 2018 05:10:53 CEST Kurt Schwehr wrote:
>> The auto&& is really confusing.
>
> A experimentally working alternative with miminal use of '&' is
>
>     for( auto poLayer: poDS->GetLayers() )  <-- this is a plain OGRLayer*

IMHO, it's better to get users familar with these two:

auto const& - as preferred default
auto& - where one requires, explicitly

It should cover 99.9% of uses :)

Best regards,
-- 
Mateusz Loskot, http://mateusz.loskot.net
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to