[omniORB] Two bugs in omniidl

Gellule Xg gellule.xg at free.fr
Fri Dec 12 17:23:32 GMT 2008


> Isn't the cxx backend having the type of problems with the following 
> IDL, where myM::myS and myM::myI::myS clash?
> 
> module myM {
>    struct myS {
>       boolean myB;
>    };
>    interface myI {
>       void myS();
>       void myC(in myM::myS myP};
>    };
> };
> 
> I notice issues in the hh file:
> 
> void myC(const myS& myP);
> ==> void myC(const *myM::*myS& myP);
> 
> virtual void myC(const myS& myP) = 0;
> ==> virtual void myC(const *myM::*myS& myP) = 0;
> 
> and in the SK.cpp file:
> 
> void myM::_objref_myI::myC(const myS& myP)
> ==> void myM::_objref_myI::myC(const *myM::*myS& myP)
> 
> _call_desc.arg_0 = &(myS&) myP;
> ==> _call_desc.arg_0 = &(*myM::*myS&) myP;

I've used the interactive mode of omniidl (-i option) and checked that 
at least to that point things are alright. Parameter "myP" does show up 
as having scoped named "myM::myS". Must be in the back-end...

After trial and error within the cxx back-end, I managed to make things 
compile with the following patch. Don't know if I've broken anything 
else. The logic for the change would be: the environment to use for a 
method should include the containing interface.

-Gellule



Index: iface.py
===================================================================
RCS file: 
/cvsroot/omniorb/omni/src/lib/omniORB/omniidl_be/cxx/Attic/iface.py,v
retrieving revision 1.1.6.15
diff -r1.1.6.15 iface.py
256c256
<     environment = self.callable().interface().environment()
---
 >     environment = 
self.callable().interface().environment().enter("_objref_"+self.callable().interface().name().simple())
691c691
<                                      self._environment)
---
 > 
self._environment.enter(self.name().simple()))




More information about the omniORB-list mailing list