[Qgis-developer] Corrections of QgsOgrProvider implementaion of GDAL 2.0

Mark Johnson mj10777 at googlemail.com
Mon Mar 20 16:23:17 PDT 2017


>
> Yet I still see lots of code in that PR like:
>
> if defined(GDAL_VERSION_NUM) && GDAL_VERSION_NUM >=
> GDAL_COMPUTE_VERSION(2,0,0)
>
> That's what I'm referring to. All this conditional code needs removal
> (unless it's testing for something in GDAL > 2.0 ).


Mosty in the static functions
- QgsOgrProviderUtils, mostly with a switch

and a few elsewhere.

There are also few for much older versions
#if defined(GDAL_VERSION_NUM) && GDAL_VERSION_NUM >= 1400

They are easy to remove.

There is one (at least) that must remain

#if defined(GDAL_COMPUTE_VERSION) && GDAL_VERSION_NUM >=
GDAL_COMPUTE_VERSION(2,1,2)

I count 20, beforehand there were many more.

There also other classes sped around the project that uses OGR
- some of which also have these

Mark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20170321/011ffb4a/attachment.html>


More information about the Qgis-developer mailing list