On Sat, Apr 27, 2019 at 04:47:52PM +0100, Stuart Henderson wrote:
> On 2019/04/24 02:14, Landry Breuil wrote:
> > CVSROOT:    /cvs
> > Module name:        ports
> > Changes by: [email protected]  2019/04/24 02:14:17
> > 
> > Modified files:
> >     geo/pdal       : Makefile distinfo 
> >     geo/pdal/patches: patch-cmake_macros_cmake 
> >     geo/pdal/pkg   : PLIST 
> > Added files:
> >     geo/pdal/patches: patch-vendor_arbiter_arbiter_hpp 
> > Removed files:
> >     geo/pdal/patches: patch-cmake_modules_FindGEOS_cmake 
> >                       patch-dimbuilder_CMakeLists_txt 
> >                       patch-pdal_PluginDirectory_cpp 
> >                       patch-pdal_util_CMakeLists_txt 
> >                       patch-pdal_util_Utils_cpp 
> >                       patch-plugins_sqlite_io_SQLiteCommon_hpp 
> >                       patch-test_unit_PluginManagerTest_cpp 
> > 
> > Log message:
> > Update to pdal 1.9.0.
> > 
> > Should build fine with python 3.7.
> > 
> 
> This breaks on i386 in a source file for tests, 
> test/unit/filters/DelaunayFilterTest.cpp,
> 
>      88     // Loop through the triangles of the generated mesh...
>      89     for (size_t i = 0; i < mesh->size(); i++)
>      90     {
>      91         Triangle triangle = (*mesh)[i];
>      92
>      93         // Build a vector so we can compare to an expected triangle 
> with
>      94         // the == operator.
>      95         std::vector<size_t> triangleVector = {triangle.m_a, 
> triangle.m_b, triangle.m_c};
>      96
> 
> /usr/obj/ports/pdal-1.9.0/PDAL-1.9.0-src/test/unit/filters/DelaunayFilterTest.cpp:95:47:
>  error: non-constant-expressio
> n cannot be narrowed from type 'pdal::PointId' (aka 'unsigned long long') to 
> 'unsigned long' in initializer list [-Wc+
> +11-narrowing]
>         std::vector<size_t> triangleVector = {triangle.m_a, triangle.m_b, 
> triangle.m_c};
>                                               ^~~~~~~~~~~~
> /usr/obj/ports/pdal-1.9.0/PDAL-1.9.0-src/test/unit/filters/DelaunayFilterTest.cpp:95:47:
>  note: insert an explicit cast
>  to silence this issue
>         std::vector<size_t> triangleVector = {triangle.m_a, triangle.m_b, 
> triangle.m_c};
>                                               ^~~~~~~~~~~~
>                                               static_cast<unsigned long>( )

Well, going the dumb wayi and adding the proposed static_cast seems to
work here, builds both on amd64 & i386 without extra warnings. does this
look better?

http://pastebitch.com/hXMD

Landry

Reply via email to