[omniORB] idl mapping to structs

Leandro Fanzone leandro@hasar.com
Thu, 19 Jul 2001 13:29:02 -0300


I'm using gcc 3.0 and it compiles OK. It doesn't work without the "StructTest::"
because I'm not within the structure and obviously the idea is to declare the
operator== outside it to avoid derivation.

Kevin Bailey wrote:

> On Thu, Jul 19, 2001 at 12:57:18PM -0300, Leandro Fanzone wrote:
> >
> > bool
> > operator==(const StructTest::SomeStruct &Left, const StructTest::SomeStruct
> > &Right)
> > {
> >     return Left.l == Right.l;
> > }
>
> That might work on gcc 2.95.x but gcc 3.x (and the new standard)
> require that operator== be declared in the same scope as the
> type it compares, so the StructTest:: should be unnecessary.