#860: Prefer empty to size of zero ------------------------+--------------------------- Reporter: goatbar | Owner: geos-devel@… Type: defect | Status: new Priority: major | Milestone: 3.6.3 Component: Default | Version: 3.6.2 Severity: Unassigned | Resolution: Keywords: | ------------------------+---------------------------
Comment (by goatbar): And there are some easy to find instances of the same thing: {{{ find . -name \*.cpp | xargs egrep '[.]size()' | egrep '== *0|0 *==' ./geomgraph/EdgeEndStar.cpp: if (edgeMap.size()==0) return nullCoord; ./geomgraph/EdgeEndStar.cpp: if (edgeMap.size()==0) return true; ./operation/buffer/SubgraphDepthLocater.cpp: if (stabbedSegments.size()==0) return 0; ./operation/overlay/LineBuilder.cpp: if ( v3d.size() == 0 ) ./linearref/ExtractLineByLocation.cpp: if (newCoordinateArray.size() == 0) }}} -- Ticket URL: <https://trac.osgeo.org/geos/ticket/860#comment:1> GEOS <http://trac.osgeo.org/geos> GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).
_______________________________________________ geos-devel mailing list geos-devel@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/geos-devel