[Fwd: Re: [omniORB] IDL name clashes]

mdavis@rwii.com mdavis@rwii.com
Wed, 6 Sep 2000 22:14:22 -0400


There are two ways that I cna interpret what you are asking :

a)

    module A
    {
        module B
        {
            interface A
            {
            }
        }
    }

b)

    module A
    {
        interface B
        {
        }
    }

    module C
    {
        interface B
        {
        }
    }

regardless, I think both are valid.

On Wed, Sep 06, 2000 at 10:10:37AM +0100, Richard Gruet wrote:
> 
> 
> -------- Original Message --------
> Subject: Re: [omniORB] IDL name clashes
> Date: Wed, 06 Sep 2000 10:08:35 +0100
> From: Richard Gruet <rgruet@ina.fr>
> Reply-To: rgruet@ina.fr
> Organization: INA
> To: Craig Rodrigues <rodrigc@mediaone.net>
> References: <39B523AE.447C307D@ina.fr>
> <20000905122617.A2498@mediaone.net>
> 
> Craig,
> 
> OK, I already knew that rule, but it does not clarify my point. Is it or
> not
> allowed in IDL to use SAME identifiers (or differing only by case) in
> DIFFERENT
> scopes ? I could interpret the section 3.2.3 of the CORBA 2.3
> specification that
> you quote as concerning only identifiers in the SAME scope. And your
> example
> doesn't illustrate my specific question.
> 
> What do you think ? Any other advice (eg from the omniidl gurus) ?
> 
> Richard Gruet
> 
> Craig Rodrigues wrote:
> 
> > On Tue, Sep 05, 2000 at 05:47:42PM +0100, Richard Gruet wrote:
> > > Hi omniORBers,
> > >
> > > When compiling the following IDL:
> > >
> > > module m {
> > >     interface M {
> > > };
> > > };
> >
> > Your IDL is buggy, omniidl is doing the right thing.
> >
> > (Other IDL compilers like JavaIDL and Visibroker 3.3 don't pick up this bug.)
> >
> >  From section 3.2.3 of the CORBA 2.3 specification:
> >
> >  " When comparing two identifiers to see if they collide:
> >    Upper- and lower-case letters are treated as the same letter.   Table 3-2
> > +defines the equivalence mapping of upper- and lower-case letters.   All
> > +characters are significant.  Identifiers that differ only in case   collide,
> >  and will yield a compilation error under certain circumstances.   An
> > +identifier for a given definition must be spelled identically   (e.g., with
> > +respect to case) throughout a specification.
> >
> >  module M {
> >    typedef long Foo;
> >    const long thing = 1;
> >    interface thing { // error: reuse of identifier
> >    void doit (
> >        in Foo foo // error: Foo and foo collide and refer to
> >                    // different things
> >              );
> >    readonly attribute long Attribute; // error: Attribute collides with
> > // keyword attribute
> >    };
> >  };
> > --
> > Craig Rodrigues
> > http://www.gis.net/~craigr
> > rodrigc@mediaone.net

-- 
Mike Davis           Real World Interface, a division of I.S. Robotics
mdavis@rwii.com      http://www.rwii.com
603-532-6900 x215    fax : 603-532-6901