On the python console in QGIS what is the difference between the following two code snippets (activeLayer is a polygon layer):
# 1) iface.activeLayer().selectedFeatures().geometry().type() >>> 3 # 2) f = iface.activeLayer().selectedFeatures() f.geometry().type() >>> 2
In case 1) the result is '3', in case 2) the result is '2', and moreover in QGIS 2.12 using 'asPolygon()' instead of 'type()' case 2) gives as list of qPoints as expected while in case 1) QGIS says goodbye with a 'Runtime Error! ... R6025 - pure virtual function call' (in QGIS 2.8 results in an empty list).
I expected the same results.