Boost 1.44 incompatible with RTT v1?

This program


#include <rtt/TaskContext.hpp>
#include <rtt/Method.hpp>

template <typename TTT>
void f()
{
    RTT::TaskContext* peer=0;
  RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
}

void f2()
{
       RTT::TaskContext* peer=0;
  RTT::Method<int(void)> method = peer->methods()->getMethod<int(void)>("xxx");
}


fails to compile on a Mac with boost v1.44 with


g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx -fPIC -I/opt/local/include
x.cpp: In function ‘void f()’:
x.cpp:7: error: expected primary-expression before ‘>’ token


Works under Mac OS X with boost v1.42.

Is this a known issue? Nothing turned up when searching the forum and ML.
S

Boost 1.44 incompatible with RTT v1?

On Wednesday 24 November 2010 20:40:25 S Roderick wrote:
> This program
>
> 
> #include <rtt/TaskContext.hpp>
> #include <rtt/Method.hpp>
> 
> template <typename TTT>
> void f()
> {
>  RTT::TaskContext* peer=0;
>      RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
> }
> 
> void f2()
> {
>       RTT::TaskContext* peer=0;
>      RTT::Method<int(void)> method =
> peer->methods()->getMethod<int(void)>("xxx"); }
>
>
> fails to compile on a Mac with boost v1.44 with
>
> 
> g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx -fPIC
> -I/opt/local/include x.cpp: In function ‘void f()’:
> x.cpp:7: error: expected primary-expression before ‘>’ token
>
>
> Works under Mac OS X with boost v1.42.
>
> Is this a known issue? Nothing turned up when searching the forum and ML.

Not that I know. You're sure TTT isn't expanded to some macro ?

Peter

Boost 1.44 incompatible with RTT v1?

On Nov 24, 2010, at 15:45 , Peter Soetens wrote:

> On Wednesday 24 November 2010 20:40:25 S Roderick wrote:
>> This program
>>
>> 
>> #include <rtt/TaskContext.hpp>
>> #include <rtt/Method.hpp>
>> 
>> template <typename TTT>
>> void f()
>> {
>>      RTT::TaskContext* peer=0;
>>  RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
>> }
>> 
>> void f2()
>> {
>>   RTT::TaskContext* peer=0;
>>  RTT::Method<int(void)> method =
>> peer->methods()->getMethod<int(void)>("xxx"); }
>>
>>
>> fails to compile on a Mac with boost v1.44 with
>>
>> 
>> g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx -fPIC
>> -I/opt/local/include x.cpp: In function ‘void f()’:
>> x.cpp:7: error: expected primary-expression before ‘>’ token
>>
>>
>> Works under Mac OS X with boost v1.42.
>>
>> Is this a known issue? Nothing turned up when searching the forum and ML.
>
> Not that I know. You're sure TTT isn't expanded to some macro ?

Tried TTT, T, ... didn't make any difference ... I'll get the guy to try it just in case ...
S

Boost 1.44 incompatible with RTT v1?

On Nov 24, 2010, at 15:57 , Stephen Roderick wrote:

> On Nov 24, 2010, at 15:45 , Peter Soetens wrote:
>
>> On Wednesday 24 November 2010 20:40:25 S Roderick wrote:
>>> This program
>>>
>>> 
>>> #include <rtt/TaskContext.hpp>
>>> #include <rtt/Method.hpp>
>>> 
>>> template <typename TTT>
>>> void f()
>>> {
>>>  RTT::TaskContext* peer=0;
>>>      RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
>>> }
>>> 
>>> void f2()
>>> {
>>>       RTT::TaskContext* peer=0;
>>>      RTT::Method<int(void)> method =
>>> peer->methods()->getMethod<int(void)>("xxx"); }
>>>
>>>
>>> fails to compile on a Mac with boost v1.44 with
>>>
>>> 
>>> g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx -fPIC
>>> -I/opt/local/include x.cpp: In function ‘void f()’:
>>> x.cpp:7: error: expected primary-expression before ‘>’ token
>>>
>>>
>>> Works under Mac OS X with boost v1.42.
>>>
>>> Is this a known issue? Nothing turned up when searching the forum and ML.
>>
>> Not that I know. You're sure TTT isn't expanded to some macro ?
>
> Tried TTT, T, ... didn't make any difference ... I'll get the guy to try it just in case ...
> S

s/TTT/ABC/g produces no change.

Boost 1.44 incompatible with RTT v1?

On Wednesday 24 November 2010 22:01:25 S Roderick wrote:
> On Nov 24, 2010, at 15:57 , Stephen Roderick wrote:
> > On Nov 24, 2010, at 15:45 , Peter Soetens wrote:
> >> On Wednesday 24 November 2010 20:40:25 S Roderick wrote:
> >>> This program
> >>>
> >>> 
> >>> #include <rtt/TaskContext.hpp>
> >>> #include <rtt/Method.hpp>
> >>> 
> >>> template <typename TTT>
> >>> void f()
> >>> {
> >>> 
> >>>        RTT::TaskContext* peer=0;
> >>>         RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
> >>> 
> >>> }
> >>> 
> >>> void f2()
> >>> {
> >>> 
> >>>        RTT::TaskContext* peer=0;
> >>>         RTT::Method<int(void)> method =
> >>> 
> >>> peer->methods()->getMethod<int(void)>("xxx"); }
> >>>
> >>>
> >>> fails to compile on a Mac with boost v1.44 with
> >>>
> >>> 
> >>> g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx
> >>> -fPIC -I/opt/local/include x.cpp: In function ‘void f()’:
> >>> x.cpp:7: error: expected primary-expression before ‘>’ token
> >>>
> >>>
> >>> Works under Mac OS X with boost v1.42.
> >>>
> >>> Is this a known issue? Nothing turned up when searching the forum and
> >>> ML.
> >>
> >> Not that I know. You're sure TTT isn't expanded to some macro ?
> >
> > Tried TTT, T, ... didn't make any difference ... I'll get the guy to try
> > it just in case ... S
>
> s/TTT/ABC/g produces no change.

Well, I'd still like to see the pre-processed code (-E). Could you send it in
private ?

Peter

Boost 1.44 incompatible with RTT v1?

On Nov 24, 2010, at 16:20 , Peter Soetens wrote:

> On Wednesday 24 November 2010 22:01:25 S Roderick wrote:
>> On Nov 24, 2010, at 15:57 , Stephen Roderick wrote:
>>> On Nov 24, 2010, at 15:45 , Peter Soetens wrote:
>>>> On Wednesday 24 November 2010 20:40:25 S Roderick wrote:
>>>>> This program
>>>>>
>>>>> 
>>>>> #include <rtt/TaskContext.hpp>
>>>>> #include <rtt/Method.hpp>
>>>>> 
>>>>> template <typename TTT>
>>>>> void f()
>>>>> {
>>>>> 
>>>>>        RTT::TaskContext* peer=0;
>>>>>      RTT::Method<TTT> method = peer->methods()->getMethod<TTT>("xxx");
>>>>> 
>>>>> }
>>>>> 
>>>>> void f2()
>>>>> {
>>>>> 
>>>>>   RTT::TaskContext* peer=0;
>>>>>      RTT::Method<int(void)> method =
>>>>> 
>>>>> peer->methods()->getMethod<int(void)>("xxx"); }
>>>>>
>>>>>
>>>>> fails to compile on a Mac with boost v1.44 with
>>>>>
>>>>> 
>>>>> g++ -o x -c x.cpp -I /path/to/install/include -DOROCOS_TARGET=macosx
>>>>> -fPIC -I/opt/local/include x.cpp: In function ‘void f()’:
>>>>> x.cpp:7: error: expected primary-expression before ‘>’ token
>>>>>
>>>>>
>>>>> Works under Mac OS X with boost v1.42.
>>>>>
>>>>> Is this a known issue? Nothing turned up when searching the forum and
>>>>> ML.
>>>>
>>>> Not that I know. You're sure TTT isn't expanded to some macro ?
>>>
>>> Tried TTT, T, ... didn't make any difference ... I'll get the guy to try
>>> it just in case ... S
>>
>> s/TTT/ABC/g produces no change.
>
> Well, I'd still like to see the pre-processed code (-E). Could you send it in
> private ?

This problem occurs when using gcc 4.0 against Boost v1.44. The same operating system (Mac OS X Leopard) with an upgraded (gcc 4.2) compiler is fine, as is Debian Lenny (i386) with gcc 4.1 and Mac OS X Snow Leopard with gcc 4.2
S