[omniORB] omniORBpy and module re-opening

Duncan Grisby dgrisby@uk.research.att.com
Fri, 13 Jul 2001 14:40:20 +0100


On Friday 13 July, Michele Bini wrote:

> I also tried placing explicit import ifA2_idl in various places in 
> test3.py but, altough something from ifA2_idl is imported in module A, 
> some other stuff isn't (ironically the symbol ifA2_idl isn't) and, 
> despite this is not exercised by these examples, this messes things up 
> and _narrow() doesn't work as expected.

Explicitly importing ifA2_idl should work. It doesn't matter that
ifA2_idl isn't imported into module A, since it isn't used. What
problem do you get with _narrow?  Can you post an example?

[...]
> Is this the expected behaviour of omniORBpy? Anybody has a 
> workaround/suggestion?

It is the expected behaviour in the sense that that's what the
implementation does. It isn't quite right according to the
specification, but I'm not sure it's actually possible to get it
right. I think the only way to fix the problem you are seeing would
cause problems with idl with circular dependencies. I'll think about
it, though.

Apart from the workaround of importing ifA2_idl, which should work,
another simple thing is to #include <A/ifA2.idl> in ifB2.idl. That
will mean that when you import B, both ifA1_idl and ifA2_idl are
imported.

Cheers,

Duncan.

-- 
 -- Duncan Grisby  \  Research Engineer  --
  -- AT&T Laboratories Cambridge          --
   -- http://www.uk.research.att.com/~dpg1 --