List Info

Thread: Does 'ic' (the CORBA IDL compiler) support recursive types?




Does 'ic' (the CORBA IDL compiler) support recursive types?
user name
2007-10-23 07:37:44
Hello,

This is not strictly a bug report, but a question for
clarification: Is 
it correct that the 'ic' IDL compiler does
not support recursive types? Forward declarations or
self-references 
result in a "syntax error"/"undeclared
identifier":

enum NodeType { Empty, Tuple };

// union Tree; // doesn't help either

union Tree switch (NodeType) {
case NT_Tuple: sequence< Tree > p;
};

Can't find the restriction mentioned in the manual.

Sebastian
_______________________________________________
erlang-bugs mailing list
erlang-bugserlang.org
ht
tp://www.erlang.org/mailman/listinfo/erlang-bugs

Re: Does 'ic' (the CORBA IDL compiler) support recursive types?
country flaguser name
Sweden
2007-10-23 08:17:57
Hello!

It's correct, IC doesn't support recursive types. The only
way is to avoid
using rescursive structures (i.e. change the IDL
specification). Note,
Anonymous Types was deprecated in CORBA-2.4:

 sequence <A> next; // Deprecated.

Unless you must represent a tree, you can use:

  struct A {
    long i;
  };
  typedef sequence<A> ASeq;

After a quick search in my mail boxes I found that the last
time someone
asked about rescursive types was back in Nov 2003. As you
understand,
since it's seldom used and one can solve this in other ways,
it hasn't
been a high prio IC extension.

/Niclas

On Tue, 23 Oct 2007, Sebastian Egner wrote:

> Hello,
> 
> This is not strictly a bug report, but a question for
clarification: Is 
> it correct that the 'ic' IDL compiler does
> not support recursive types? Forward declarations or
self-references 
> result in a "syntax error"/"undeclared
identifier":
> 
> enum NodeType { Empty, Tuple };
> 
> // union Tree; // doesn't help either
> 
> union Tree switch (NodeType) {
> case NT_Tuple: sequence< Tree > p;
> };
> 
> Can't find the restriction mentioned in the manual.
> 
> Sebastian
> _______________________________________________
> erlang-bugs mailing list
> erlang-bugserlang.org
> ht
tp://www.erlang.org/mailman/listinfo/erlang-bugs
> 





_______________________________________________
erlang-bugs mailing list
erlang-bugserlang.org
ht
tp://www.erlang.org/mailman/listinfo/erlang-bugs

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )