Opened 8 years ago

Closed 8 years ago

#10177 closed Bugs (fixed)

boost/geometry/strategies/cartesian/distance_pythagoras.hpp does not include boost/numeric/cast/conversion.hpp

Reported by: smspillaz@… Owned by: Barend Gehrels
Milestone: Boost 1.57.0 Component: geometry
Version: Boost 1.54.0 Severity: Problem
Keywords: compiler-error Cc:

Description

This results in a compiler error when the latter header is not included before the former about a missing boost::numeric_cast.

Boost version by apt-cache policy libbopst-dev

apt-cache policy libboost-dev libboost-dev:

Installed: 1.54.0.1ubuntu1 Candidate: 1.54.0.1ubuntu1 Version table:

* 1.54.0.1ubuntu1 0

500 http://au.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages 100 /var/lib/dpkg/status

Change History (4)

comment:1 by awulkiew, 8 years ago

This should be fixed now, this commit:

https://github.com/boostorg/geometry/commit/48bb75137da9473f2707d31f4b7f7e2d02931aac

adds

#include <boost/geometry/util/math.hpp>

which includes <boost/numeric/conversion/cast.hpp>

Or should it be included explicitly in distance_pythagoras.hpp?

comment:2 by smspillaz@…, 8 years ago

That depends - are end users permitted to use distance_pythagoras.hpp directly?

comment:3 by awulkiew, 8 years ago

Yes, more enlightened user should be able to include e.g. only the algorithm and the strategy he needs.

To be perfectly clear. The commit mentioned above adds the required include indirectly: distance_pythagoras.hpp -> boost/geometry/util/math.hpp -> boost/numeric/conversion/cast.hpp

comment:4 by awulkiew, 8 years ago

Milestone: To Be DeterminedBoost 1.57.0
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.