[Boost-bugs] [Boost C++ Libraries] #11268: Regression in boost::geometry::intersection interface with multi_linestring and box -- does not compile on 1.57 VS 1.55

Subject: [Boost-bugs] [Boost C++ Libraries] #11268: Regression in boost::geometry::intersection interface with multi_linestring and box -- does not compile on 1.57 VS 1.55
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-05-05 01:44:16


#11268: Regression in boost::geometry::intersection interface with multi_linestring
and box -- does not compile on 1.57 VS 1.55
------------------------------+---------------------------
 Reporter: anonymous | Owner: barendgehrels
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: geometry
  Version: Boost 1.57.0 | Severity: Regression
 Keywords: |
------------------------------+---------------------------
 Consider the following block of code, the boost::geometry::intersection
 between a multi-linestring and a box compiles and works on boost 1.55, but
 fails to compile with boost 1.57

 {{{
 #include <cstdlib>
 #include <boost/geometry.hpp>
 #include <boost/geometry/geometry.hpp>
 #include <boost/geometry/geometries/point_xy.hpp>
 #include <boost/geometry/geometries/linestring.hpp>
 #include <boost/geometry/geometries/box.hpp>
 #include <boost/geometry/multi/geometries/multi_linestring.hpp>
 #include <boost/foreach.hpp>

 int main()
 {
     typedef boost::geometry::model::d2::point_xy<double> Point;
     typedef boost::geometry::model::box<Point> Box;
     typedef boost::geometry::model::linestring<Point> Linestring;
     typedef boost::geometry::model::multi_linestring<Linestring>
 MultiLinestring;

     Box box;
     Linestring ls;
     MultiLinestring mls;
     MultiLinestring out;

     // Case 1 - linestring with box
     // 1.55: OK
     // 1.57: OK
     boost::geometry::intersection(ls, box, out);

     // Case 2 - multi linestring with box
     // 1.55: OK
     // 1.57: ERROR - does not compile
             // clip_linestring.hpp:166:16: note: candidate function
 template not viable: requires 4 arguments, but 5 were provided
             // OutputIterator clip_range_with_box(Box const& b, Range
 const& range,
     boost::geometry::intersection(mls, box, out);

     return 0;
 }
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/11268>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:18 UTC