|
Boost Users : |
Subject: Re: [Boost-users] [ICL] intersects(interval_set< int >, int) doesn't compile
From: John Reid (j.reid_at_[hidden])
Date: 2011-02-18 09:11:46
On 18/02/11 12:38, Jeff Flinn wrote:
> John Reid wrote:
>> AFAICT from the docs the following should compile:
>>
>> #include <boost/icl/interval_set.hpp>
>>
>> namespace icl = ::boost::icl;
>>
>> void interval_set_intersects() {
>> icl::intersects( icl::interval_set< int >(), 1 );
>> }
>>
>>
>>
>> but I get a no match error:
>>
>> gcc.compile.c++ bin/gcc-4.4.3/debug/src/sandbox.o
>> src/sandbox.cpp: In function void interval_set_intersects():
>> src/sandbox.cpp:7: error: No match for
>> intersects(boost::icl::interval_set<int, less,
>> boost::icl::discrete_interval<int, less>, allocator> &, int)
>
> Just a shot, but have you noticed the first argument is by reference,
> and you are passing a temporary? Does the following work:
>
> {
> icl::interval_set<int> iclset;
>
> icl::intersects( iclset, 1 );
> }
Good point but it doesn't change things.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net