mirror of
https://github.com/boostorg/geometry.git
synced 2026-02-09 11:12:21 +00:00
[algorithms][detail] make sure we are not going to get an unused
variable warning (on MSVC)
This commit is contained in:
@@ -10,6 +10,8 @@
|
||||
#ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_CHECK_ITERATOR_RANGE_HPP
|
||||
#define BOOST_GEOMETRY_ALGORITHMS_DETAIL_CHECK_ITERATOR_RANGE_HPP
|
||||
|
||||
#include <boost/core/ignore_unused.hpp>
|
||||
|
||||
|
||||
namespace boost { namespace geometry
|
||||
{
|
||||
@@ -46,6 +48,10 @@ struct check_iterator_range
|
||||
InputIterator beyond,
|
||||
Predicate const& predicate)
|
||||
{
|
||||
// in case predicate's apply method is static, MSVC will
|
||||
// complain that predicate is not used
|
||||
boost::ignore_unused(predicate);
|
||||
|
||||
for (InputIterator it = first; it != beyond; ++it)
|
||||
{
|
||||
if ( !predicate.apply(*it) )
|
||||
|
||||
Reference in New Issue
Block a user