Boost C++ Libraries: Ticket #13039: geometry::difference with multi_linestring and multi_polygon needs geometry.hpp to compile with MinGW/LLVM https://svn.boost.org/trac10/ticket/13039 <div class="wikipage" style="font-size: 80%"><p> Code highlighting: </p> <div class="wiki-code"><div class="code"><pre><span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">multi_polygon</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">polygon</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">d2</span><span class="p">::</span><span class="n">point_xy</span><span class="o">&lt;</span><span class="nb">float</span><span class="o">&gt;</span> <span class="p">,</span> <span class="n">false</span><span class="p">,</span> <span class="n">false</span><span class="o">&gt;</span> <span class="o">&gt;</span> <span class="n">myMultiPolygon</span><span class="p">;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">multi_linestring</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">linestring</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">d2</span><span class="p">::</span><span class="n">point_xy</span><span class="o">&lt;</span><span class="nb">float</span><span class="o">&gt;</span> <span class="o">&gt;</span> <span class="o">&gt;</span> <span class="n">myMultiLineString</span><span class="p">;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">multi_linestring</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">linestring</span><span class="o">&lt;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">model</span><span class="p">::</span><span class="n">d2</span><span class="p">::</span><span class="n">point_xy</span><span class="o">&lt;</span><span class="nb">float</span><span class="o">&gt;</span> <span class="o">&gt;</span> <span class="o">&gt;</span> <span class="n">myMultiLineStringOut</span><span class="p">;</span> <span class="n">boost</span><span class="p">::</span><span class="n">geometry</span><span class="p">::</span><span class="n">difference</span><span class="p">(</span><span class="n">myMultiLineString</span><span class="p">,</span> <span class="n">myMultiPolygon</span><span class="p">,</span> <span class="n">myMultiLineStringOut</span><span class="p">);</span> </pre></div></div></div><p> On MinGW 5.3.0 with <a class="missing wiki">QtCreator</a>, it ouput: boost\boost\geometry\algorithms\detail\overlay\intersection_insert.hpp:403: error: no matching function for call to 'assertion_failed(mpl_::failed<strong></strong><strong></strong><strong></strong> (boost::geometry::dispatch::intersection_insert&lt;boost::geometry::model::multi_linestring&lt;boost::geometry::model::linestring&lt;boost::geometry::model::d2::point_xy&lt;float&gt; &gt; &gt;, boost::geometry::model::multi_polygon&lt;boost::geometry::model::polygon&lt;boost::geometry::model::d2::point_xy&lt;float&gt;, false, false&gt; &gt;, boost::geometry::model::linestring&lt;boost::geometry::model::d2::point_xy&lt;float&gt; &gt;, (boost::geometry::overlay_type)2u, false, false, false, boost::geometry::multi_linestring_tag, boost::geometry::multi_polygon_tag, boost::geometry::linestring_tag, false, true, false&gt;::NOT_OR_NOT_YET_IMPLEMENTED_FOR_THIS_GEOMETRY_TYPES_OR_ORIENTATIONS::<strong></strong><strong></strong><strong></strong>)(mpl_::assert_::types&lt;boost::geometry::model::multi_linestring&lt;boost::geometry::model::linestring&lt;boost::geometry::model::d2::point_xy&lt;float&gt; &gt; &gt;, boost::geometry::model::multi_polygon&lt;boost::geometry::model::polygon&lt;boost::geometry::model::d2::point_xy&lt;float&gt;, false, false&gt; &gt;, boost::geometry::model::linestring&lt;boost::geometry::model::d2::point_xy&lt;float&gt; &gt;, mpl_::na&gt;))' </p> <blockquote> <p> BOOST_MPL_ASSERT_MSG <sup> </sup></p> </blockquote> <p> It works on Visual Studio 2015. </p> <p> And it's the same with a line_string instead of the multi_linestring. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/13039 Trac 1.4.3 bruno.deligny@… Mon, 22 May 2017 09:33:32 GMT summary changed https://svn.boost.org/trac10/ticket/13039#comment:1 https://svn.boost.org/trac10/ticket/13039#comment:1 <ul> <li><strong>summary</strong> <span class="trac-field-old">geometry::difference with multi_linestring and multi_polygon doesn't compile with MinGW</span> → <span class="trac-field-new">geometry::difference with multi_linestring and multi_polygon needs geometry.hpp to compile with MinGW/LLVM</span> </li> </ul> <p> It also doesn't compile on LLVM MacOSX/iOS either. </p> <p> I included: </p> <div class="wikipage" style="font-size: 80%"><p> Code highlighting: </p> <div class="wiki-code"><div class="code"><pre><span class="c1">#include &lt;boost/geometry/geometries/polygon.hpp&gt;</span> <span class="c1">#include &lt;boost/geometry/geometries/multi_polygon.hpp&gt;</span> <span class="c1">#include &lt;boost/geometry/geometries/linestring.hpp&gt;</span> <span class="c1">#include &lt;boost/geometry/geometries/multi_linestring.hpp&gt;</span> <span class="c1">#include &lt;boost/geometry/geometries/point_xy.hpp&gt;</span> <span class="c1">#include &lt;boost/geometry/algorithms/difference.hpp&gt;</span> </pre></div></div></div><p> I thought it was sufficient but it compile if i also include: </p> <div class="wikipage" style="font-size: 80%"><p> Code highlighting: </p> <div class="wiki-code"><div class="code"><pre><span class="c1">#include &lt;boost/geometry.hpp&gt;</span> </pre></div></div></div> Ticket