[omniORB] omniORB4 idl compiler code generation issue

Duncan Grisby duncan at grisby.org
Thu Dec 15 12:04:16 GMT 2005


On Sunday 4 December, "Terry Lee" wrote:

[...]
>   _CORBA_MODULE_VAR inline CmdBuf_t_slice* CmdBuf_t_alloc() {
>     return new CmdBuf_t_slice[1024];
>   }
> 
> The problem is that _CORBA_MODULE_VAR is defined
> as extern and this does not compile on all platforms
> for example on IRIX:
> 
> cc-1300 CC: ERROR File = HDSObjects.h, Line = 65
>   "inline" is not allowed.
> 
> _CORBA_MODULE_VAR inline CmdBuf_t_slice* CmdBuf_t_alloc() {

I think it's valid C++. There's even an example in Stroutrup's book that
does it (albeit in an example of invalid code, but it's not the extern
inline that's invalid).

Regardless, any sensible compiler will inline the functions without the
inline declaration, so I've removed it from the generated code.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan at grisby.org     --
   -- http://www.grisby.org --



More information about the omniORB-list mailing list